Read-only archive of the All About Symbian forum (2001–2013) · About this archive

accessing underlying file system with PJava

1 replies · 1,933 views · Started 16 September 2004

Hi,
I've heard that with PersonalJava, it possible to access the underlying file system on the mobile device (e.g. P900). I would like to be able to load a JPG image (stored on my device) into my PJava application. Could someone give me an example line of code that shows how this can be done?

Thanks,

Pete

ee8prt wrote:Hi,
I've heard that with PersonalJava, it possible to access the underlying file system on the mobile device (e.g. P900). I would like to be able to load a JPG image (stored on my device) into my PJava application. Could someone give me an example line of code that shows how this can be done?

Thanks,

Pete

Something like:

FileDialog fd = new FileDialog(this, "Open file", FileDialog.LOAD);
fd.show();
if (fd.getFile() == null) {
return;
}
currentFile = fd.getDirectory() + fd.getFile();
fd.dispose();

Hope this helps.

Malcolm
www.freepoc.org