iOS create file
NSFileHandle
might not have a method to create a file, but NSFileManager
has one. Have you looked at that class?
This works fine for me, however note that it will overwrite the same file each time
NSString *cachesFolder = [NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES) lastObject];
NSString *file = [cachesFolder stringByAppendingPathComponent:@"testfile"];
[[NSData data] writeToFile:file options:NSDataWritingAtomic error:nil];