I'm a beginner. I am doing a popover when a button is pressed which then instantiates another view controller where the user can select from 5 choices. I want to be able to save the sender.tag of the button from the first view controller (where code snippet below came from) and pass it to the second where I can save them together to Parse. I'm not using a segue so I can't pass it that way. Thanks in advance!
func showPopover(sender: UIButton) {
let vc = self.storyboard?.instantiateViewControllerWithIdentifier("SelectionViewController")
vc!.modalPresentationStyle = .Popover
vc!.preferredContentSize = CGSizeMake(150, 30)
if let presentationController = vc!.popoverPresentationController {
presentationController.delegate = self
presentationController.permittedArrowDirections = .Up
presentationController.sourceView = self.view
presentationController.sourceRect = sender.frame
self.presentViewController(vc!, animated: true, completion: nil)
}
}