iOS 9 Segue Causes App To Freeze (no crash or error thrown)

So basically the segue was freezing because of the UITextView‘s I was using in the destinationViewController. The following fixed the issue: Delete all UITextView‘s Add new UITextView’s you must leave the default lorem imposed text and change this programmatically in the viewDidLoad() This was the fix for me, and from the research I have done … Read more

How do I create a segue that can be called from a button that is created programmatically?

Here is how to set up a segue so that it can be called programmatically. Control drag from the ViewController icon in the first view controller to the second view controller. Click on the segue arrow between the two view controllers, and in the Attributes Inspector on the right, give the segue an Identifier (tableau … Read more

Prepare for Segue in Swift

This seems to be due to a problem in the UITableViewController subclass template. It comes with a version of the prepareForSegue method that would require you to unwrap the segue. Replace your current prepareForSegue function with: override func prepareForSegue(segue: UIStoryboardSegue!, sender: AnyObject!) { if (segue.identifier == “Load View”) { // pass data to next view … Read more

Passing Data between View Controllers in Swift

Let’s assumed we stand at the firstView go to the DetailView and want passing data from firstView to Detailview. To do that with storyboard, at the firstView we will have a method: override func prepareForSegue(segue: UIStoryboardSegue!, sender: AnyObject!) { if (segue.identifier == “segueTest”) { //Checking identifier is crucial as there might be multiple // segues … Read more