I have a storyboard set up in XCode and have a MainViewController. In the MainViewController I have added a ContainerView which naturally creates a Segue with another VIewCo
This is pretty much the same answer as the one by rdelmar only in Swift.
override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
if let embeddedVC = segue.destinationViewController as? MyEmbeddedController where segue.identifier == "EmbedSegue" {
embeddedVC.labelString = self.stringToPass
}
}
"EmbedSegue" has to the segue identifier you set in Interface Builder.