I occasionally the following scenario when trying to debug my multi-threaded app. I run the program and then a bug occurs causing a useful message to appear in the log cat... but only for about a quarter of a second before scrolling off the top of the window because a seemingly never-ending stream of of not-so useful error messages floods into the window. I am then left desperately trying to grab the vertical scroll bar (which is now jiggling around) so as to position the original error message into the window before the window buffer becomes so full that it is discarded.
There must be a better way... Is there a "stop-logging-now" command/button that I can hit as soon as the errors start appearing?
Using -d option will get you a one-time run of logcat. The command above is to clean the logs in logcat buffer. Show activity on this post. -c Clears (flushes) the entire log and exits.
you just click on the line three times and you can selectd the line , it will stops scrolling. Doesn't work here (1.2. 2).
Logcat is a command-line tool that dumps a log of system messages, including stack traces when the device throws an error and messages that you have written from your app with the Log class. This page is about the command-line logcat tool, but you can also view log messages from the Logcat window in Android Studio.
The Logcat window in Android Studio displays system messages, such as when a garbage collection occurs, and messages that you added to your app with the Log class. It displays messages in real time and keeps a history so you can view older messages.
I've solved it. I just pull the USB cable out.
Not the most elegant solution... but it works.
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