I have a show segue between two ViewControllers in my Storyboard. When call performSegueWithIdentifier:
, I get an NSInvalidArgumentException
:
Receiver (<[MY VIEWCONTROLLER SUBCLASS]: 0x7fc9e99f0640>) has no segue with identifier 'HomeToSettings''
The segue definitely exists and is connected, and there are many other segues on the same origin ViewController that work fine.
In the source code for the storyboard, the segue shows up just like all the working ones:
<connections>
<outlet property="notificationsButton" destination="hG9-8E-sv6" id="mn0-1x-Qxj"/>
<outlet property="settingsButton" destination="Fy0-au-d6J" id="r1c-fG-KOP"/>
<outlet property="tableView" destination="9bJ-Cd-hc3" id="Wuy-hJ-QVU"/>
<segue destination="ad8-yH-D5h" kind="show" identifier="HomeToCreateList" id="bsg-J2-Gp3"/>
//More segues...
<segue destination="pNX-Jw-wau" kind="show" identifier="HomeToNotifications" id="B2t-BE-YpW"/>
<segue destination="xge-ah-WXM" kind="show" identifier="HomeToSettings" id="nTa-qO-SCb"/>
</connections>
I have tried:
- Renaming the storyboard
- Deleting and recreating the segue
- Renaming the segue
- Cleaning the project
- Reinstalling the app
- Reset content and settings on the simulator
- Physical device
Xcode and iOS are up to date as of June 1, 2016.
If it's somehow important, I am triggering the segue through an IBAction attached to a UIBarButtonItem. However, another segue to a different ViewController from another UIBarButtonItem works perfectly.
The exact line with which I'm calling the segue is:
[self performSegueWithIdentifier:@"HomeToSettings" sender:self];
I'm really lost here.