I have a strange issue using JFileChooser. I have implemented a WebApplication with a browse option to a folder(not files). For this JFileChooser has been used. Strangely when I click on "Browse" button, the controller calls the JAVA class, and the dialog opens behind the browser (only for the first time). and next time onwards it opens on the browser only. Here is the code i have written:
This problem seems a lot like this problem. In short, JFileChooser is a client-side component whereas the web application runs on the server. You can't use JFileChooser in web applications unless you are going to use applets.