Set aside implementation details for a second; what are you actually trying to accomplish?
The short answer, to respond to the question as you've phrased it here, is that it's impossible(*) to write a browser-based application (with GWT, hand-crafted JavaScript, or any toolkit) that will programmatically retrieve a list of files on the client. Browser security rules forbid anything like that (for obvious reasons -- it would be Very Not Good if any random web page had the ability to go snooping around in your filesystem). (*) In this context, "impossible" disregards messing around with local security policy files and/or using browser-specific hacks. On Aug 16, 12:14 pm, DemiSheep <[email protected]> wrote: > I am using the Google Toolkit and I have created a widget with a > listbox, vertical split panel and a couple of buttons. What I am > trying to do is have a list of files in a local directory listed in > the listbox and I want to be able to click on a file and have it > displayed in the top part of the split panel. I found out the hard way > about browsers and file IO and not being able to use java.io.File. > > What are my options? Can I put the data files inside a jar or > something and have the widget read it in that way? I need to do this > as a test run, to implement an new feature with working with the data. > It's not going to be any kind of final server hosted application, I am > not concerned about how the actual files will be loaded in the future. > > Any suggestions would be greatly appreciated. > > Respectfully, > DemiSheep -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
