I have app in eclipse that was running well lately
Now it suddenly stops.
After I hit debug code runs and there is breakpoint in it.
From there on I am unable to debug and go step by step through the code because ther is no pointer showing me current line code at all.
Als o I noticed that all buttons in Run menu are grayed out (Terminate, REsume, Disconnect all of them)
So the only way to stop program running is to shut down eclipse
Any ideas ?
#Tobia
yes i saw the red button but unfortunatelly that did not helped. eclipse is such crap that can not be fixed with 1 red button. i had to downoad 32bit version and now it looks like it is working. 2nd issue now i have: THE ONLY way i ca nstart this crap app is to use -clean -clearPersistedState switches. ANYONE KNOWS IF THIS ECLIPSE CAN RUN NORMALY ?
just hit the red square on the top of the menu. Or also you can go to your device and stop your application, from settings->apps->yourapp->force stop or something like.
Related
The log cat does not show anything.Clicking on the debug button does't do anything different.
What you are looking at is the Console, not LogCat. It is a separate tab in Android Studio.
Try pressing Alt+6 on Windows or CMD+6 on Mac.
look at the debug menu in the toolbar of android studio beside run , after selecting your breakpoint ,hit that button then open debugger console ,this should work.
did you select breakpoint ? if you just want to see the Log messages then you should see Andorid Monitor , if you want to debug then you have to select breakpoint
Open Android Monitor, and look for a tab named Logcat. This is where logs are printed. You can use stdout logs as well as stderr.
For open the LogCat :
on Windows or Linux : Alt+6
on MacOS : command+6
First you will have to set a breakpoint in your android studio. A breakpoint is a point in your code where you want the app to pause waiting your reaction like seeing variables value and the app in your device or virtual device will also pause as well. By default android studio should open the debugger tab when it finds a break point.
So this is how you set a break point:
Go your code may be in an Activity find a line of code you want to debug in your app (The one close to or the one which you think it brings the error).
In android studio there are line numbers column on the left just go there and just right of that particular number click once and the red dot will appear. Thats your breakpoint. Then just do the same for any other line you want to debug.
After that just click on the Button for debugging. In case you dont know it go to the tab Run and choose the Debug app. And now when you run your app will pause in your breakpoint and you will read all variables.
I have configured a VD through Eclipse and it starts up fine. If I press F11 from one of my .java files in my application project, it starts up a new instance of the emulator and installs the app on it. However it does not open the app and if I manually open it and click on action buttons, it plainly is not linked up to the IDE for debugging as no break points get hit.
Other times when the emulator is open, F11 does the job of re-installing the app (after I manually uninstall it from the emulator), but again it does not attach as a debugger, just installs the app so I can run it.
Is there something basic I am doing wrong so that step-through debugging is not working?
Eclipse having option Skip All Breakpoints,
it might be possible you enable this option so you need to disable Skip All Breakpoints,
Option will appear when you will right click on project and trying to run it.
You can also do it by UI of eclipse , figure out this images. there are a option, if you toggle this button option it will behave disabe/ enable
I'm new to Java, haven't used Eclipse in probably 2 years. We're starting up a mobile dev team at work, and I'm just going over the tutorials on the Android site:
http://developer.android.com/training/basics/firstapp/running-app.html
Simply just created a project, launched the virtual device manager, have that emulator running, then click Run -> Run as Android application in Eclipse .
I've been staring at this screen for about 5 minutes now:
It says "Launching (100%)" in the bottom right corner of eclipse, and this Progres window just says Launching, but the emulator isn't doing anything.
I know emulators are generally pretty slow... But is this normal or did I do something wrong?
That happened to me too, and still does at times:
Close the emulator and execute the program again
If that didn't work, execute the program while the emulator is running. A new emulator will pop up, close the old emulator
If that didn't work, delete device and create a new one.
Also, is there anything at all popping up on the Logcat view?
I would recommand checking the list of process afterwards. Sometimes when i brutally terminate an app in eclipse, the process is still running.
But i'm on PC and i use an older version. Maybe it has been fixed.
I'm coming from Visual studio and C# and am new to Android (and eclipse) so quite ignorant of basic functionality.
I've written a short app and ran it under the emulator. No problems.
Now I've made some changes and want to test them. In VS I'd stop the application debug run before making code changes, and after the code changes run again.
I can't find the 'stop' debug button in eclipse. How do I run my app after I've made changes?
What you can do is press the [Escape] key on your keyboard or the 'Back' button within the Emulator to close your app then rebuild and run it in Eclipse, which should bring it up as active in the Emulator.
You can just run it again and the code changes will apply.
But else you'll find it under the Debug-window (Window->Show View->Debug) and there is a "terminate" button in the top right corner of your screen.
You might need to close the app inside the emulator though..
There is deference between just running the application and debugging, you can pres play in ellipse and that will run the app but what you can also do is to switch the perspective in debug view (to switch go to the right top corner, and change from java to debug perspective)
in debug mode you can also set break points, just like in visual studio the only difference here is you must change perspective
This is my first time running Eclipse on a mac. For some reason, when I launch an app in the emulator, while the console tells me that it successfully started the app, I can't see an emulator window anywhere. I know its running bc when I tried again, console told me "Activity not started, its current task has been brought to the front."
How do I find the emulator?!
Did you try cycling through open applications with command-tab or clicking on the application icon in the dock? Running applications will have a bright dot under them.
Ok, I'm using MotoDev Studio. Apparently I had to click the little cell phone icon in the bottom right to bring up the emulator.
Thanks all!