My issue for my function is I am not sure how to pass the data which i selected, and back to the previous view controller. The link is to the whole paragraph,http://pastebin.com/AtMjLD66 (sorry I don't have 10 reputations, sorry about the inconvenience ) Cheer.
相关问题
- CALayer - backgroundColor flipped?
- Core Data lightweight migration crashes after App
- How can I implement password recovery in an iPhone
- State preservation and restoration strategies with
- “Zero out” sensitive String data in Swift
相关文章
- 现在使用swift开发ios应用好还是swift?
- UITableView dragging distance with UIRefreshContro
- TCC __TCCAccessRequest_block_invoke
- Where does a host app handle NSExtensionContext#co
- xcode 4 garbage collection removed?
- Unable to process app at this time due to a genera
- Swift - hide pickerView after value selected
- How can I add media attachments to my push notific
I would recommend delegates for this but if you don't want to do so, NSNotification would save your day here.
Add this is in advanceVC.m probably in viewDidLoad
And in didSelect of advanceDetailVC.m do this.
Instead of passing a label's text you have the indexpath here so take it directly from the array and pass it in the notification like this
You can use nsuserdefault to save data and then you can retrieve back in the previous class
You would use the delegate pattern to send a message back to the view controller's delegate (which you could set to the presenting view controller), passing along whatever information you need to about the selection.
Assuming you want it for iOS, a simple call :
or Since you only have one view controller, the generic way (independent of how your app was set up):