1

I want to log my iPhone application activity in a log file on the device. Could you please let me know how can I do that? How can I access the file?

Thanks.

ebaccount
  • 5,051
  • 11
  • 43
  • 47

1 Answers1

0

Yes, you can do this. see

How do I debug with NSLog(@"Inside of the iPhone Simulator")?

which reviews a number of approaches of getting log information from the simulator or from the iphone (tethered) while using the development environment.

Community
  • 1
  • 1
Alex Brown
  • 41,819
  • 10
  • 94
  • 108
  • Yes, this is the way I am doing now, viewing the NSLog output/printf in XCode. However, I wanted the log info to be saved as a text file on the device. – ebaccount Jun 17 '09 at 23:12
  • If what you want is a way to get logs back from your developer hardware after using it untethered, or from non developer users, that's a different question you could ask. Do you expect these logs to show normal or abnormal behaviour? – Alex Brown Jun 17 '09 at 23:12
  • I have done this in the past, looking for evidence of it now in my git logs. – Alex Brown Jun 17 '09 at 23:13
  • You might find this page interesting. http://recapturing.blogspot.com/2009/05/getting-paths-to-directories-of-iphone.html – Alex Brown Jun 17 '09 at 23:39