PassWordViewController

PassWordViewController

在ios中,rootview为PassWordViewController,secondview为SecondViewController,实现在rootview中听过一个跳转按钮实现跳转到secondview中,实现方法如下:

在PassWordViewController.h中添加button的事件

-(IBAction) landButtonPressed:(id) sender;

在PassWordViewController.m中 button的实现事件如下:

-(IBAction) landButtonPressed:(id) sender

{

SecondViewController *logViewController=[[SecondViewControlleralloc]init];

[self.view addSubview:logViewController.view];

}

04-14 07:05