The Android logging system provides a mechanism for collecting and viewing system debug output. Logs from various applications and portions of the system are collected in a series of circular buffers, which then can be viewed and filtered by the
Logcat can be viewed from commend line or from eclipse.
navigate to <android sdk/platform-tools> and then type ./adb logcat to view logcat from command line.
Open Eclipse and select Window->show view->others->Android->Logcat you will get this window.
The Logcat is capable of identifying the line number which has the error. In this above Logcat sample take a close look at this line
02-24 16:47:18.200: W/System.err(13914): at android.org.Weight_mode.getCount(Weight_mode.java:640)
It says there is a warning in getCount function which is in line number 640 in weight_mode.java file. So branch to that line and make the required changes.