Return NSString from UIViewController

后端 未结 2 1865
清歌不尽
清歌不尽 2021-01-16 16:40

I want to return a NSString * from a UIViewController, called InputUIViewController, to the previous UIViewController, called CallerUIViewController, which star

2条回答
  •  生来不讨喜
    2021-01-16 17:26

    You can do this by simply creating a NSString object as property in prvious view controller and when in second view you call dismissModelViewControllerAnimated then before it assign value to previous view controller property. This might help you -

    Passing data between classes using Objective-C

提交回复
热议问题