jjzjj

selectionString

全部标签

ios - 当 viewController 转到另一个 tableViewController 时,我如何保存字符串的值

好吧,这个问题听起来确实很奇怪,但我找不到更好的表达方式。我很确定这是一个基本错误,但我卡住了。我有一个主主页ViewController,有2个按钮导致2个不同的tableViewController。我将使用这两个选项。但是当我从一个TableView中获取选定的索引并转到下一个时,第一个的值变为空。if(tempFromLocationString!=NULL){//tempFromLocationString=@"asd";fromLocationLabel.text=tempFromLocationString;}if(tempToLocationString!=NULL){