2011年12月7日
摘要: 1。http://cenphoenix.iteye.com/blog/709691某些打不开需翻()墙Customizing the background/border colors of a UITableView (grouped style)http://pessoal.org/blog/2009/02/25/customizing-the-background-border-colors-of-a-uitableview/UITableViewCell Dynamic Heighthttp://www.cimgf.com/2009/09/23/uitableviewcell-dynam 阅读全文
posted @ 2011-12-07 16:53 wtq 阅读(346) 评论(0) 推荐(0) 编辑
摘要: 1:原文摘自:http://mobile.51cto.com/iphone-282233.htmiPhone文件读写系统操作教程是本文要介绍的内容,对于一个运行在iPhone得app,它只能访问自己根目录下得一些文件(所谓sandbox).一个app发布到iPhone上后,它得目录结构如下:1、其中得 app root 可以用 NSHomeDirectory() 访问到;2、Documents 目录就是我们可以用来写入并保存文件得地方,一般可通过:NSArray*paths=NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, N.. 阅读全文
posted @ 2011-12-07 15:41 wtq 阅读(342) 评论(0) 推荐(0) 编辑
摘要: 1:原文摘自:http://wonderzl.iteye.com/blog/1007642当保存完成后,调用的回调方法:Obj-c代码-(void)image:(UIImage*)imagedidFinishSavingWithError:(NSError*)errorcontextInfo:(void*)contextInfo{//Wasthereanerror?if(error!=NULL){//Showerrormessage…NSLog(@"Saveimagefailed");}else//Noerrors{//Showmessageimagesuccessfull 阅读全文
posted @ 2011-12-07 15:36 wtq 阅读(942) 评论(0) 推荐(0) 编辑
摘要: 1:本文摘自:http://mobile.51cto.com/iphone-281443.htmiPhone应用开发之学习点滴iPhone应用开发中学习点滴是本文要介绍的内容,主要介绍了IPhone之NSBundle的使用、IPhone之ASINetworkQueue 异步队列、IPhone之获取Settings设置的内容,来看本文内容详解。IPhone之NSBundle的使用NSBundle的对象可以获取应用程序安装目录的附件。附件包括了,当前应用程序下,所有的文件。(图片、属性列表等)获取XML文件NSString*filePath=[[NSBundlemainBundle]pathFor 阅读全文
posted @ 2011-12-07 15:14 wtq 阅读(315) 评论(0) 推荐(0) 编辑
摘要: 1:原文摘自:http://mkhgg.blog.51cto.com/1741572/554134 1.stringWithFormat 用法: [NSStringstringWithFormat:@"Hight:%d°%@Low:%d°%@",[Temp],@"C",[lTemp],@"C"]; NSString to NSData:NSString* str= @"kilonet";NSData*data=[str dataUsingEncoding:NSUTF8StringEncoding 阅读全文
posted @ 2011-12-07 15:10 wtq 阅读(211) 评论(0) 推荐(0) 编辑
摘要: 1原文摘自:http://mobile.51cto.com/iphone-283165.htmiPhone应用开发中缓存文件是本文要介绍的内容,在iPhone应用程序中,我们经常要用去网络下载一些文件,比如xml,图片等等!但是往往我们经常是需要反复读取这部分数据,或者我们要写一些文件在沙箱中,供下次打开程序的时候使用,这时候我们就需要用到缓存文件(读写文件),今天和大家分享一个Demo,用来缓存从网上下载下来的图片和xml;项目背景:下载从网络下载图片,并写在temp目录下,temp目录下的文件在程序退出时会被清空,所以用来写本次要用的缓存内容很合适(我这么觉得)。1、从一个url下载图片N 阅读全文
posted @ 2011-12-07 14:52 wtq 阅读(672) 评论(0) 推荐(0) 编辑
摘要: 原文摘自:http://www.apple.com.cn/developer/iphone/library/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/AudioandVideoTechnologies/AudioandVideoTechnologies.html#//apple_ref/doc/uid/TP40007072-CH19-SW39 阅读全文
posted @ 2011-12-07 14:04 wtq 阅读(155) 评论(0) 推荐(0) 编辑
摘要: 1,使用数组遍历某一文件夹中的图片,代码如下: NSFileManager *fileManager = [NSFileManager defaultManager]; NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory,NSUserDomainMask, YES); NSString *documentsDirectory = [paths objectAtIndex:0]; NSLog(@"%d",[paths count]); NSError *error = nil; NS 阅读全文
posted @ 2011-12-07 13:41 wtq 阅读(443) 评论(0) 推荐(0) 编辑
摘要: 1利用FileManage来读取document的文件NSFileManager *fileManager = [NSFileManager defaultManager]; NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory,NSUserDomainMask, YES); NSString *documentsDirectory = [paths objectAtIndex:0]; NSError *error = nil; NSArray *fileList = [[NSArray alloc.. 阅读全文
posted @ 2011-12-07 11:28 wtq 阅读(316) 评论(0) 推荐(0) 编辑
摘要: 1.保存图片到document目录下:代码如下:View Code2.从document目录下显示显示图片代码如下:View Code 阅读全文
posted @ 2011-12-07 10:24 wtq 阅读(544) 评论(0) 推荐(0) 编辑
摘要: 1原文摘自:http://ruixiazun.blog.163.com/blog/static/906879182011229112144105/在开发iPhone程序时,有时候要对文件进行一些操作。而获取某一个目录中的所有文件列表,是基本操作之一。通过下面这段代码,就可以获取一个目录内的文件及文件夹列表。NSFileManager *fileManager = [NSFileManager defaultManager];//在这里获取应用程序Documents文件夹里的文件及文件夹列表 NSArray *documentPaths = NSSearchPathForDirectoriesI 阅读全文
posted @ 2011-12-07 08:56 wtq 阅读(632) 评论(0) 推荐(0) 编辑
摘要: 1:原文摘自:http://www.cocoachina.com/bbs/read.php?tid=32931我在Documents文件中建了一个文件夹fileName, 文件夹保存的有一张图片.我想读出来并在UIImageView中显示,这如何实现呢?下面是我写的代码,不知道哪出问题了??#import <UIKit/UIKit.h>@interfaceUIView{UIImageView *image;}@property (nonatomic, retain) IBOutlet UIImageView *image;@end@implementationNSFileManag 阅读全文
posted @ 2011-12-07 08:55 wtq 阅读(1031) 评论(0) 推荐(0) 编辑
摘要: 1.本文摘自:http://mobile.51cto.com/iphone-278789.htmiPhone应用AVAudioPlayer播放音频讲解是本文要介绍的内容,iPhone是媒体大师,其内建的iPod功能可轻松的处理音频和视频,下面我将对AVAudioPlayer这个音频播放类详细的介绍。使用AVAudioPlayer可以实现载入、播放、暂停、停止音频,监控平均和峰值音量水平.AVAudioPlayer处理音频中断当用户在音频回放期间受到电话时,音频会消失,出现这种情况时AVAudioPlayer委托接受audioPlayerBeginInterruption:回调,音频会话暂时无效 阅读全文
posted @ 2011-12-07 08:37 wtq 阅读(588) 评论(0) 推荐(0) 编辑