ios 页面跳转
来源:互联网 发布:sql 2008 r2 数据同步 编辑:程序博客网 时间:2024/04/29 13:41
MyThreeController 跳转到 MyFourController
1、点击new file生成cocoa Touch Class
2、 A、MyThreeController.h 定义方法
- (IBAction)openFourController:(id)sender;
B 、MyThreedController.m 实现方法
- (IBAction)openFourController:(id)sender { UIStoryboard *mainStory = [UIStoryboard storyboardWithName:@"Main" bundle:nil]; MyFourController *myfourview=[mainStory instantiateViewControllerWithIdentifier:@"myfourcontroller"]; myfourview.delegate = self; [self presentViewController:myfourview animated:NO completion:nil]; //[self performSegueWithIdentifier:@"mythreecontroller" sender:sender]; // //调用此方法显示模态窗口 // [self.navigationController pushViewController:mythreeview animated:YES];}
C、MyFourController.h
#import<UIKit/UIKit.h>@protocol MyThreeDelegate@end@interface MyFourController : UIViewController @property (nonatomic) id<MyThreeDelegate> delegate;@end
D、MyFourController.m
#import "MyFourController.h"@interface MyFourController()@end@implementation MyFourController@end
3、 步骤一:点击storyboard
步骤二:拖拽View Controller 控件到storyboard
步骤三:修改storyboard ID 和class 名字 ()
4、command+R 运行即可
0 0
- ios 页面跳转问题
- ios 页面跳转
- IOS之页面跳转
- iOS 页面跳转方式
- ios ViewController 页面跳转
- IOS 页面跳转
- ios页面跳转基础
- ios ViewController 页面跳转
- ios ViewController 页面跳转
- ios ViewController 页面跳转
- ios ViewController 页面跳转
- ios ViewController 页面跳转
- IOS页面跳转方法
- iOS页面跳转
- [IOS]页面跳转 相关
- ios ViewController 页面跳转
- ios ViewController 页面跳转
- ios ViewController 页面跳转
- Linux 创建共享对象,共享库并安装使用共享库
- vector中erase用法注意事项
- c++笔试题:简易学生信息系统
- hihoCoder 1233 Boxes
- 华为OJ(求字符串中最后一个单词的长度)
- ios 页面跳转
- 如何用LINUX命令格式化U盘
- 【Python】Learn Python the hard way, ex5 格式化字符串
- 收藏几个安卓镜像地址
- Tomcat连接池的配置
- 解决 js 中文乱码问题小技巧
- Android启动Run As是报 Installation error: INSTALL_FAILED_INSUFFICIENT_STORAGE错误
- GCT试题训练感受及总结
- 用python进行项目实训的计划