Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Contributor
Consilium
Posts: 13
Registered: ‎07-12-2010
My Device: Any

Stacktrace logging

Hi there,

 

I am catching my exceptions like so

catch(Throwable t)
{
		
	t.printStackTrace();
			
}

 I am logging my events like so

 

 

 

EventLogger.logEvent(Guid.eventLogId, ("bla bla").getBytes(), EventLogger.INFORMATION);

 How do I use Eventlogger to log the StackTrace of an error?

 

Many thanks

 

Developer
simon_hain
Posts: 16,282
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport

Re: Stacktrace logging

did you try

http://www.blackberry.com/developers/docs/5.0.0api/java/lang/Throwable.html#getMessage() ?

we use getMessage an getClass().getName() to log errors with throwable.

----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Contributor
Consilium
Posts: 13
Registered: ‎07-12-2010
My Device: Any

Re: Stacktrace logging

Yeah , tried many options as well.

 

Gave up.