【发布时间】:2015-10-07 05:33:27
【问题描述】:
我是ios开发新手。
我有两个视图控制器。
-(IBAction)clickToview:(id)sender
{
[self performSegueWithIdentifier:@"1" sender:self];
}
-(void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender
{
if ([segue.identifier isEqualToString:@"1"]) {
second *destViewController = segue.destinationViewController;
destViewController.labA.text=textA.text; // here i want to set values in labA to labB. in second view .
destViewController.labB.text=textB.text;
NSLog(@"labA ");
}
}
-(void)viewDidLoad
{
textA.text=@"London "; // this is my text fields
textB.text=@"Dreams ";
[super viewDidLoad];
}
【问题讨论】:
-
信不信由你,有几个重复的标题完全相同。我无法想象如果您实际使用过 Google,您至少找不到其中一个或网站搜索。
-
另外,这与 Xcode 无关——这是一个语言/算法/API 问题,如果你使用
make和emacs编写你的 iOS 并没有什么不同应用程序。 -
-
@HotLicks 如果问题是“如何在 Interface Builder 中而不是通过编写代码”IMO,这只会与 Xcode 相关。
标签: ios objective-c