Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Monaj

macrumors regular
Original poster
May 24, 2009
193
0
hi
i made an iphone application when i give the absolute path it run fine.i.e
NSURL *xmlURL = [NSURL fileURLWithPath:mad:"/Users/Abn/Desktop/iphoneTry/questionBank.xml"];

But when i give the relative path it did not parse the file.
NSURL *xmlURL = [NSURL fileURLWithPath:mad:"questionBank.xml"];

Error:-
ERROR:Operation could not be completed. (NSXMLParserErrorDomain error 5.)

In general info tab, path type is : relative to enclosing group
file type:text.xml


thanks
 
You can't use relative paths like that, only absolute paths. Use NSSearchPathForDirectoriesInDomains() to find common folders, or NSBundle to get a file in your .app's bundle.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.