I'm trying to do some basic logging while I work on an app. I tossed some NSLog()
s into my code, but nothing is being printed to the Xcode console below. Literally nothing, not even some startup info as the app launches, etc.
I've got my Xcode console set to display All Output
and I've got the variable inspector and the Console open:
I heard about Logging changes and that a new Console.app was introduced that would let me view the logs on the simulators as well, so I thought maybe the logs would show up over there, but while I do so lots of system messages happening I don't see the NSLog()s that I'm making.
Am I missing something? Is there a new setting I need to flip? Where can I see my NSLog()s?
EDIT:
I was doing this with an iOS 11 simulator and got no console output. When I switched to an iOS 9 simulator then I got all of the console output.
NSLog() output on the simulator does indeed show up in the Console Mac OS X application. Go to All Messages and then filter based on your app name to get rid of the fluff, and run again. You'll see it in your output if the NSLog code is actually being hit during the execution of your program.
Go to Xcode → Preferences → Debugging → On Start → "Show Console".
In Xcode 4 short cut to display and hide console is (command-shift-Y) , this will show the console and debugger below ur text edior in the same window.
Figured it out. It's not an intermittent issue or one that can just be fixed with a restart. It's a Run configuration issue.
Click on the Run Scheme selector in the top left of Xcode's toolar.
Click Manage Schemes.
Click on your main App Project.
Click the Edit button in the bottom left.
Uncheck OS_ACTIVITY_MODE
.
Click Close.
Viola. All your console logs come back.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With