更新时间:2022-12-14 19:48:27
对于您的Ex;
假设你要传递一个int的值
Suppose you want to pass the value of an int
在下一个视图控制器中:在中复制它* * .h **
file
In Next view controller: copy this in **.h**
file
@property( assign)int temp;
@property (assign) int temp;
2。
SSPUserLogedInViewController * logInView =
[[SSPUserLogedInViewController alloc] init];
>
2. SSPUserLogedInViewController *logInView = [[SSPUserLogedInViewController alloc] init]; >
logInView.modalTransitionStyle = UIModalTransitionStyleCoverVertical;
logInView.temp = <YOUR_VALUE>
[self presentViewController:logInView animated:YES completion:nil];
**。m **
文件**.m**
file
- (void)viewWillAppear
-(void)viewWillAppear
{
NSLog(@"My Value = %i",_temp);
}
享受编程!!