How to see the Exception thrown by the Blackberry Application
I am new to Blackberry Development. In my app it is throwing an Exception,it is showing on simulator. I want to know how can I see this exception in detail like 'Logcat' in Android.
开发者_如何学CThanks in Advance
Try like this:
try {
//write code here;
}
catch(final Exception e)
{
UiApplication.getUiApplication().invokeLater(new Runnable()
{
public void run()
{
Dialog.alert("Exception: "+e.getMessage());
System.exit(0);//if you want to close the application;
}
});
}
Enough; If you have doubts come on StackOverFlow chat room name "Life for Blackberry" to clarify Your and our doubts
try{
......
.....
}
catch(Exception ce){
System.out.println(ce.getMessage());
}
if you are using ECLIPSE just run the application in DEBUG mode....
Then check for whichever exception occured in console pane.
精彩评论