title: Problem in parsing .plist file
body: <p>I've one plist file and I want to parse it and copy it's content into NSArray,and code that I am using for that is.    </p>
  
  <pre><code>NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory,NSUserDomainMask, YES);
  
  NSString *documentsPath = [paths objectAtIndex:0];
  
  NSString *fooPath = [documentsPath stringByAppendingPathComponent:@"myfirstplist.plist"];
  NSLog(fooPath);
  self.myArray = [[NSArray arrayWithContentsOfFile:fooPath] retain];
  NSLog(@"%@",myArray);
  </code></pre>
  
  <p>Now problem is very weird, sometime when I print myArray content it prints file data, and sometime it doesn't.</p>
  
  <p>I am facing a same problem even when I use URL as my path.</p>
  
  <pre><code>self.myArray = [[NSArray arrayWithContentsOfURL:URlPath] retain];
  </code></pre>
  
  <p>what would be the reason?</p>
  
  <p>Thanks in advance.</p>