View Full Version : Hows to write data into file in /var/mobile/Documents [iPhone programming with SDK]

Dec 3, 2008, 09:59 AM
Dear All,

We are using iPhone 2.5G Firmware 2.1 Jailbreak with Apple SDK for 2.1.

I have issues with writing data (array of byetes) into file under /var/mobile/Documents. For example:

NSData* data;
BOOL ret = [data writeFile:@"/var/mobile/Documents/song.mp3"];

=> return error. => Cannot create a song file.

Would you please help me if you have indeas?
Thank you