Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Open file with MIDlet.platformRequest()

Is it possible to get a device to open a file on disk using the MIDlet.platformRequest(String url) method? I was hoping to use the following:

midlet.platformRequest("file:///path/to/file/file.png");

But this just throws a ConnectionNotFound exception. I'm specifically using the BlackBerry platform, but I do not have access to the proprietary BlackBerry API. File could be of any type, so obviously I'm not expecting it to handle every one.

Cheers

like image 795
roryf Avatar asked Jun 14 '26 07:06

roryf


1 Answers

No, it is not possible to open arbitrary files using platform request. MIDP 2.0 requires devices to support platform request only for URL and tel: connections. All other schemes are optional and device dependent.

Nokia S60 phones seems to support file:// as pointed out in forum Nokia. But you need to verify for other platforms including Blackberry.

You can look at JSR211 Content Handler API as an alternative. I believe it is supported in newer Blackberry devices.

like image 194
Szere Dyeri Avatar answered Jun 17 '26 00:06

Szere Dyeri



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!