1.新建文件iOS other如图:2.修改工程配置文件 将刚刚新建的pch文件路径添加到prefix header中去 如图:那么问题来了(刚刚pch文件的路径怎么找呢?) 如图:选中刚刚创建的pch文件 在属性栏查看该文件的路径(Full Path就是该文件的路径啦)将路径复制下来 黏贴扫下面....
分类:
其他好文 时间:
2015-02-02 13:58:57
阅读次数:
171
本文转载至http://dingran.iteye.com/blog/1773573 对于真机,日志没法保存,不好分析问题。所以有必要将日志保存到应用的Docunment目录下,并设置成共享文件,这样才能取出分析。 首先是日志输出,分为c的printf和标准的NSLog输出,printf会向...
分类:
移动开发 时间:
2015-02-02 12:06:48
阅读次数:
341
1:首先遵守协议
UIImagePickerControllerDelegate,UINavigationControllerDelegate
2:
- (void)imageChange:(UIButton *)button{
NSLog(@"调用系统相册");
if (button!=self.button) {
self.isChang...
分类:
移动开发 时间:
2015-02-02 10:50:34
阅读次数:
198
一直在用xcode6开发,但项目都是在xcode5上创建的,所以一直没注意到,xcode6竟然干掉pch文件了。为什么xcode6没有自动创建pch文件呢? 简单地看:我们在写项目的时候,大部分宏定义,头文件导入都在这里,Xcode6去掉Precompile Prefix Header的主要原...
分类:
其他好文 时间:
2015-02-01 00:37:58
阅读次数:
200
NSData *data = [NSData data]; //获取当前时间
NSLog ("Today is %@", data);
NSArray *phrase;
phrase = [NSArray arrayWithObjects: @“x”, @“y”, @“z”, @“end”];
[phrase writeToFile: @“/tmp/...
分类:
其他好文 时间:
2015-01-30 06:50:49
阅读次数:
287
- (void)inviteBtnMethod{ NSLog(@"inviteBtnMethod %@",myInviteCode.text); // [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"sms:"]]....
分类:
移动开发 时间:
2015-01-29 17:21:59
阅读次数:
176
LLDBhttps://github.com/nangege© 2015objc中国本站由@onevcat创建,文章源自objc.io,由objc中国 项目组整理维护你是否曾经苦恼于理解你的代码,而去尝试打印一个变量的值?NSLog(@"%@", whatIsInsideThisThing);或者跳...
分类:
移动开发 时间:
2015-01-26 19:13:07
阅读次数:
355
//手机序列号 //NSString* identifierNumber = [[UIDevice currentDevice] uniqueIdentifier]; //NSLog(@"手机序列号: %@",identifierNumber); [[[UIDevice currentD...
分类:
移动开发 时间:
2015-01-26 19:07:05
阅读次数:
157
先看看代码再说:
NSLog(@"Start!")
[[NSRunLoop currentRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:5]];
NSLog(@"End!")
两句NSLog打出来的时间会相差5s,那么答案就来了。
NSRunLoop将...
分类:
其他好文 时间:
2015-01-26 17:12:11
阅读次数:
222