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

Web and WebWorks Development

Reply
New Developer
mplots
Posts: 6
Registered: ‎11-02-2009
My Device: Not Specified

JVM Error 104 Uncaught: NullPointerException

Hi everyone.

I Just started developing native applications for blackberry using BlackBerry Widget SDK 1.0 Beta 1. 

 

And i keep getting an error "JVM Error 104 Uncaught: NullPointerException" when i try to deploy new version of my application on BlackBerry Smartphone Simulators 5.0.0., 9500; 

 

When i change name of my *.zip file and then compile application, then everything looks, fine but then i get two applications in Download folder. 

 

I tried to remove application from Simulator i get message "Are you sure that you want to delete null?" and when i click Delete, Simulator asks me to restart it. But it starts up really slowly so ... 

 

I have solution, but it is a hack. I created Ant Build in eclipse and with each build i'm changing *.zip file name, application version, and application name.

 

So basically question is how to get rid of that exception and deploy new version correctly.

 

Thanks. 
Maris.

Please use plain text.
BlackBerry Development Advisor
tneil
Posts: 3,708
Registered: ‎10-16-2008
My Device: Z10
My Carrier: Rogers

Re: JVM Error 104 Uncaught: NullPointerException

There are some naming limitations of the *.cod files that you load onto a BlackBerry Smartphone.

 

Can you post up the name of the zip file you are using to pass to the Widget Packager?  The *.cod file generated is based on the name of the zip used.

 

If you post up the zip file name we can see if you have any illegal characters in the name.

 

The "delete null" is a known issue on that Beta version of the simulator.

Tim Neil
Director, Application Platform & Tools Product Management
Follow me on Twitter
Please use plain text.
New Developer
mplots
Posts: 6
Registered: ‎11-02-2009
My Device: Not Specified

Re: JVM Error 104 Uncaught: NullPointerException

*.zip archive name is SRMInbox.zip. 

When i build application first time, everything works fine. But when i rebuild application with same *.zip archive name (SRMInbox.zip) and try to upload it on simulator, i get NullPointerException. At the moment i'm simply changing *.zip archive name every time i rebuild application.

And on the simulator at the end of the day there is a lot of applications installed on it :smileyhappy: .

 

Thanks about  "delete null" information. But is there any valid way to delete application from simulator while it is running? 

Please use plain text.
BlackBerry Development Advisor
tneil
Posts: 3,708
Registered: ‎10-16-2008
My Device: Z10
My Carrier: Rogers

Re: JVM Error 104 Uncaught: NullPointerException

Are you loading the application through the "File -> Load Java Application"?

 

If so, after you have run your widget you can reset the simulator using the "File -> Reset" action. We have found that in that scenario the application is removed from the simulator.  You can also get your simulator back to its original state by deleting any of the "*.dmp" files that exist in the simulator's directory.

 

Another way that I usually create my widgets, is use IIS/Apache to create a virtual directory to my widget's source.  Then I make the "src" attribute of the <content> element point to the URL of my HTML file on my web server.

 

That way whenever I want to make a change to my widget, I just close the widget make the change on my local file and then re-open the widget.  Essentially any scenario that forces a page re-load.

 

In this case you need to add the domain of your PC into the <access> whitelist.  Then the only time you need to re-compile, is if you make changes to your config.xml file.

Tim Neil
Director, Application Platform & Tools Product Management
Follow me on Twitter
Please use plain text.
New Developer
mplots
Posts: 6
Registered: ‎11-02-2009
My Device: Not Specified

Re: JVM Error 104 Uncaught: NullPointerException

Yes i'm loading application using File -> Load Java Application.

 

 

  • File->Reset  Solution: Yes it works but then simulator is restarted and it starts up really really really slowly .
  • by deleting any of the "*.dmp" files that exist in the simulator's directory: Do not work while simulator is running. "Cannot Delete file": It is used by other........"
  • Ok i don't know what is IIS/Apache, so this solution is mystery for me. But i will definitely check that. THANKS

 

Please use plain text.
BlackBerry Development Advisor
tneil
Posts: 3,708
Registered: ‎10-16-2008
My Device: Z10
My Carrier: Rogers

Re: JVM Error 104 Uncaught: NullPointerException

By IIS (Internet Information Server) or Apache Web Server.. I am referring to running a small web server on your desktop to serve up the pages for the Widget

Tim Neil
Director, Application Platform & Tools Product Management
Follow me on Twitter
Please use plain text.