BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 01-31-2010, 06:49 PM   #1 (permalink)
New Member
 
Join Date: Jan 2010
Model: 9500
PIN: N/A
Carrier: Vodafone (NL)
Posts: 2
Post Thanks: 0
Thanked 0 Times in 0 Posts
Question Netbeans development and simulator issues

Please Login to Remove!

Dear users,

I am a quite experienced Java programmer, who wants to develop for his Blackberry but can't really set up a good development envirement.

My problem
I started out trying out the official JDE, but it didn't work correctly for me because I am running an 64-bit Windows. Thus I tried to switch to Eclipse w/ Blackberry plugin as a IDE, however that wasn't working out to, because I am used to using VS2005+ or Netbeans.

So I decided to check out development for Blackberry with Netbeans, but I can't seem to set it up correctly. I already did the following:
  1. Set-up Netbeans with the J2ME plugin
  2. Downloaded and installed the (obselete) Blackberry plugin
  3. Followed the instructions from Sun to build the .alx/.cod files

But it still isn't working correctly for me, because every application that I build (correctly!) and upload to the Simulator will not show up within the simulator, thus I cannot test the application that I build. I have included a couple of 'attachments' which could help me (and future people having issues) out.

Attachments
Current software platform
  • Windows 7 Professional (64-bit)
  • JRE and JDK 32-bit installed
  • JRE and JDK 64-bit installed

Netbeans configuration
C:\Users\Alex van den Hoogen\.netbeans\6.8\config\Services\Platforms\org-netbeans-api-java-Platform\RIM_5_0_0.xml
Code:
<?xml version='1.0'?>
<!DOCTYPE platform PUBLIC '-//NetBeans//DTD J2ME PlatformDefinition 1.0//EN' 'http://www.netbeans.org/dtds/j2me-platformdefinition-1_0.dtd'>
<platform name="RIM_5_0_0" home="C:\Program Files (x86)\Research In Motion\BlackBerry JDE 5.0.0" type="CUSTOM" displayname="RIM 5_0_0" srcpath="" docpath="${platform.home}/docs/api," preverifycmd="&quot;{platformhome}{/}bin{/}preverify&quot; {classpath|-classpath &quot;{classpath}&quot;} -d &quot;{destdir}&quot; &quot;{srcdir}&quot;" runcmd="cmd /C &quot;cd /D {platformhome}{/}simulator&amp;{device}&quot;" debugcmd="cmd /C &quot;cd /D {platformhome}{/}bin&amp;jdwp&quot;">
    <device name="Blackberry" description="Blackberry">
        <optional name="JSR172" version="1.0" displayname="Java ME Web Services" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <optional name="OBEX" version="1.0" displayname="Object Exchange APIs" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <optional name="JSR179" version="1.0" displayname="Location Based APIs" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <optional name="JSR75" version="1.0" displayname="File Connection and PIM Optional Packages" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <optional name="JSR238" version="1.0" displayname="Mobile Internationalization API" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <optional name="JSR211" version="1.0" displayname="ContentHandler APIs" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <optional name="WMA" version="2.0" displayname="Wireless Messaging API" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <optional name="JSR177" version="1.0" displayname="Security and Trust Services APIs" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <optional name="JSR82" version="1.0" displayname="Java APIs for Bluetooth Wireless Technology" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <profile name="MIDP" version="2.0" displayname="Mobile Information Device Profile" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <configuration name="CLDC" version="1.1" displayname="Connected Limited Device Configuration" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
        <optional name="MMAPI" version="1.0" displayname="Mobile Media API" classpath="${platform.home}/lib/net_rim_api.jar" dependencies="" default="true"/>
    </device>
</platform>
Test application (HelloWorldDemo)
HelloWorldDemo.java
Code:
import net.rim.device.api.ui.UiApplication;

public class HelloWorldDemo extends UiApplication {

    public static void main(String[] args) {
        new HelloWorldDemo().enterEventDispatcher();
    }

    public HelloWorldDemo() {
        pushScreen(new HelloWorldScreen());
    }
}
HelloWorldScreen.java
Code:
import net.rim.device.api.ui.Field;
import net.rim.device.api.ui.component.Dialog;
import net.rim.device.api.ui.component.RichTextField;
import net.rim.device.api.ui.container.MainScreen;

public class HelloWorldScreen extends MainScreen {

    public HelloWorldScreen() {
        setTitle("Hello World, demo!");
        add(new RichTextField("Hello World!", Field.NON_FOCUSABLE));
    }

    public void close() {
        Dialog.alert("Goodbye Dudez!!");
        super.close();
    }
}
Conclusion
What is working?
  • Netbeans 6.8 with RIM autocomplete
  • Building applications (.jad/.jar)
  • Building applications (.cod/.alx)?
  • Installing applications on a real Blackberry via Desktop Manager (Storm2 9520)

What is not working?
  • Installing applications in the simulator
  • Running applications in the simulator
  • Running applications on a real Blackberry (Storm2 9520)

I hope I have been comprehensive enough so anyone can help me . Thanks in advance!
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Copyright 2004-2014 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.