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


Thank you for visiting the BlackBerry Support Community Forums.

BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)

BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.

"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."

- Kevin Michaluk, Founder, CrackBerry.com

Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.


Reply
Developer
Posts: 292
Registered: ‎07-25-2008
My Device: Passport

Eclipse 1.1 simulator hotswap shows IllegalArgumentException

So I'm getting moved up to the release version of the 1.1 Eclipse plug-in, and starting to experiment with simulator code hotswap.  (yes, I fixed the Installed JRE setting for 5.0.0 and created new Debug profiles)

 

Whenever I make a code change and click Debug again, my simulator shows a big white screen that says:

JVM Error 104

Uncaught:

IllegalArgumentException

 

If I click the touchpad button about 8 times or so, it eventually goes away, reattaches, and the new code is available for testing.

 

Has anyone else seen this error yet?  Its quite annoying and I'm not entirely sure how to debug it.

Developer
Posts: 1,055
Registered: ‎01-25-2009
My Device: BlackBerry Bold 9650/BlackBerry Torch 9800

Re: Eclipse 1.1 simulator hotswap shows IllegalArgumentException

I get it every once in a while but I'm not sure how I repeat it. I believe if the application is not fully loaded, it'll have that effect.

Jerome Carty - Follow jcarty on Twitter@jcarty | #webworks-dev / #BlackberryDev on irc.freenode.net | My Apps
Click "Accept as Solution" if post solved your original issue.. Give like/thumbs up if you feel post is helpful
Developer
Posts: 292
Registered: ‎07-25-2008
My Device: Passport

Re: Eclipse 1.1 simulator hotswap shows IllegalArgumentException

I did some further debugging, and I think I know what may be generating the exception now...

 

Its something that happens while my app's auto-start code is executed during the hotswap process.  I'm not sure whether my auto-start code is doing something unusual, or if the hotswap process causes it to execute before all my app's cod files are reloaded.  Regardless, it'll require further investigation.

 

Anyone else run into strange issues with hotswap on apps that have an alternate entry point that runs on device startup?

Developer
Posts: 292
Registered: ‎07-25-2008
My Device: Passport

Re: Eclipse 1.1 simulator hotswap shows IllegalArgumentException

Okay, hoping that someone else will notice this thread after another post, I'll add some more details...

 

When my auto-start code runs during device/simulator initialization, it works fine.

 

When my app is replaced during the new simulator hot-swap process, that auto-start code runs again.  That time, everything still works except two calls:

HomeScreen.updateIcon()

HomeScreen.setRolloverIcon()

 

Both of those calls throw multiple uncaught IllegalArgumentExceptions onto the simulator.  All the other calls I do at auto-start continue to work fine.

 

Now here's the fun part...  If I stick a Thread.sleep() at the top of my auto-start code (to hopefully make things settle first), it causes the whole routine to exit.  (So instead of pausing, the auto-start code ceases to execute at all.)