简体   繁体   中英

How can i use a breakpoint in Eclipse in runtime android code?

I did double click on the left gray area near a line. But when im running the program it dosent stop there its just keeping running. What is the reason that it dosent stop ? I tried to install JDT maybe its not installed so i run through the Eclipse help menu for updates but it didnt find any updates.

So i cant figure out whats wrong.

Do the following steps to debug your code :

To enable debugging in complete application, after putting breakpoints just run your application in debug mode as shown in this screenshot : 在此输入图像描述

To start debugging from a point, just navigate in your application at that point in emulator/device and then do the following : 1. Go to Windows --> Show View --> Other...

在此输入图像描述

a window will open..Select " Android " folder then select "Devices" and click OK.

在此输入图像描述

then open devices view you can identify it by phone icone, the select your device from the list and then select your package from the packages list then click green bulb on top. the green bulb the will appear at left side of your package. Now your breakpoints should work.

在此输入图像描述

In which mode did you run your program? You need to run your program in Debug mode, only then will it stop at the breakpoints. Right click on your application file and select the option "Debug As" -> "Android Application".

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM