首页 软件开发 代码片段 objective-c ( Page 31 )

objective-c 628

#Objective-C
导航栏左右按钮 如何调左右距离

UIView *rightView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 44, 44)]; UIButton *set…

2015-05-12 590

#Objective-C
工程安全类,解决项目中经常遇到的数组越界、字典键值对为空操作等闪退问题

//Array NSArray *array = @[@1, @2]; NSLog(@"index==== %@", array[2]); NSMutableArray *muAr…

2015-05-08 475

#Objective-C
iOS把数组转化成字符串 字符串转化为数组 数组元素替换

//字符串转变为数组1 NSMutableString * str=[[NSMutableString alloc]initWithFormat:@"1,1,1,1,1,1"]; …

2015-05-08 365

#Objective-C
iOS计算器的代码实现

-(void)viewDidLoad { //初始化字符串 self.num1 = [[NSMutableString alloc]init]; self.num2 = [[NSM…

2015-05-08 833

#Objective-C
iOS清除xcode缓存和生成文件

摁快捷键 shift+command+G 调出前往文件夹框 在里面输入(这些自己拼写)/Users/(自己电脑名字)/Library/Developer/Xcode/Derived…

2015-05-07 803

#Objective-C
同步访问post方式

/登录过程 - (IBAction)logIn:(id)sender { //1.确定地址url NSString *urlString =@"http://www.xxx.com…

2015-05-06 781

#Objective-C
检索网页中的邮箱

@implementation ViewController{ NSMutableString *dataString;//邮箱字符串 } - (void)viewDidAppea…

2015-05-01 510

#Objective-C
用Xcode自带的分享功能分享到新浪微博

if (![SLComposeViewController isAvailableForServiceType:SLServiceTypeSinaWeibo]) { UIAlert…

2015-04-30 318

#Objective-C
实现将 [[0,1,2],[0,1,2,3,4,5,6]] 分成[ [0,1 ],[2 , ] ], [[0,1],[2,3]的

NSMutableArray * arr3 = [[NSMutableArray alloc] init]; for (NSArray * ss1 in _GuoneidataSo…

2015-04-30 319

#Objective-C
UIView动画特效封装(UIView+JYAnimation)

// // UIView+JYAnimation.h // // Created by mac on 15-1-7. // Copyright (c) 2015年 lijianyi…

2015-04-30 608

#Objective-C
仿新浪自动刷新完后消息下拉的效果

/** *消息背景控件label */ self.loveLabel=[[UILabel alloc]initWithFrame:CGRectMake(0, 0, self.vie…

2015-04-29 834

#Objective-C
Swift版获取当前年、月、日

var dateFormatter:NSDateFormatter = NSDateFormatter(); dateFormatter.dateFormat = "yyyy/MM…

2015-04-27 309
1 29 30 31 32 33 53