11-02-2009 09:11 AM
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.
11-03-2009 07:46 AM
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.
11-03-2009 08:05 AM
*.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 .
Thanks about "delete null" information. But is there any valid way to delete application from simulator while it is running?
11-03-2009 10:09 AM
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.
11-03-2009 12:00 PM
Yes i'm loading application using File -> Load Java Application.
11-03-2009 12:05 PM
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