File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java Micro Edition and the fly likes file browse J2ME Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Mobile » Java Micro Edition
Bookmark "file browse J2ME" Watch "file browse J2ME" New topic
Author

file browse J2ME

nitish dhar
Greenhorn

Joined: Aug 19, 2007
Posts: 11
i downloaded a file browse code from the net...it runs fine

but the problem is that after i press the view command it asks for permissions more than once to read the files inside a particular folder

I think the problem is how the code creates the file connector:



wat modifications am i supposed to make



[ August 28, 2008: Message edited by: nitish dhar ]
[ August 28, 2008: Message edited by: nitish dhar ]
nitish dhar
Greenhorn

Joined: Aug 19, 2007
Posts: 11
got it done in the preference>>security set security as manufacturer

no more access permissions now
Rhianty Alfa
Greenhorn

Joined: Dec 15, 2010
Posts: 6
how to modification this method (showFile)
InputStream fis = fc.openInputStream ();
byte[] b = new byte[1024];

int length = fis.read (b, 0, 1024);

fis.close ();
fc.close ();

TextBox viewer =
new TextBox (
"View File: " + fileName, null, 1024,
TextField.ANY | TextField.UNEDITABLE);

viewer.addCommand (back);
viewer.addCommand (exit);
viewer.setCommandListener (this);

if (length > 0) {
viewer.setString (new String (b, 0, length));
}

Display.getDisplay (this).setCurrent (viewer);

it's just show file with extension *.txt
how to read a file pdf (*.pdf)??

Regards,
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16065
    
  21

Welcome to the JavaRanch, Rhianty!

I think your answer came a little too late. We call this "awakening a zombie". Since the last post was in 2008, it's very likely that not only is Nitesh working on some other project by now, he's probably not even working for the same employer!


Customer surveys are for companies who didn't pay proper attention to begin with.
Rhianty Alfa
Greenhorn

Joined: Dec 15, 2010
Posts: 6
i don't understand what you say....
well, I apologize if I was presumptuous to write as above. I just want to find a solution to my final project.

thanks
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16065
    
  21

I wouldn't call it "presumptuous". We certainly welcome published solutions to any problem. Just pointing out that it's probably too late to help the original posters.

You can start your own thread, though anytime you have a topic of interest.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: file browse J2ME