10-02-2008 02:46 PM - edited 10-02-2008 02:49 PM
Hi there! Here's my problem. I made an application that reads an XML file and parses it using a Document Builder. Here's a snippet:
String _path = "file:///SDCard/BlackBerry/MyFile.xml";
_fc = (FileConnection)Connector.open(_path,Connector.REA
// If no exception is thrown, then the URI is valid, but the file may or may not exist.
_fc.create(); // Create the file if it doesn't exist.
_builder = DocumentBuilderFactory.newInstance().newDocumentBu
_input = _fc.openInputStream();
_doc = _builder.parse( _input );
When I run it on my simulator it works ok, but when I run it on a Blackberry an error appears saying: "Error starting <app>: Module <app> must be signed with the RIM Runtime Code Signing Key (RRT)". When the DocumentBuilderFactory and the DocumentBuilder are commented, the application works fine on a Blackberry. So I checked on the API but it doesn't say that those Libraries are signed. Anybody knows how I can fix this?
10-02-2008 03:28 PM
What BlackBerry model and handheld software version are you testing with? This can be found under Options, About on the BlackBerry.
Have you created an auto start application? Auto start applications do require signing.
10-03-2008 11:44 AM
This is what the Blackberry says:
Wireless Handheld (EDGE)
v188.8.131.52 (Platform 184.108.40.206)
I dont know what an auto start application is, but I don't think i'm doing one. I just have an UiApplication that pushes a Screen that does all the things I said before.
10-06-2008 09:38 AM
There is no work around for signing requirements. The BlackBerry Simulator by default does not enforce signing to allow for easier testing and debugging. Signature keys can be ordered here:
04-16-2009 02:58 PM
I have the same experience, where my application requires a key to run on a live device (in this case, a BlackBerry 8130 v220.127.116.11 platform 18.104.22.168) when I use the DocumentBuilderFactory, but it does not when this usage is removed.
This behavior is completely undocumented and difficult to discover. The javadoc does not say that any of the classes in the net.rim.device.api.xml.parsers package require signing. Further, the jde compiles code using this package without complaint, even if none of the restricted APIs are allowed. Also, the code thus compiled runs just fine on a simulator. Only when deploying to a live Blackberry does this behavior show up.
I like to think that restricting the use of the package is an error that will be fixed in future versions.