If I have a file system path can I open a window in Explorer (on windows) or in Finder (on OS X) displaying the folder that the path leads to?
Cookie points for answers that are cross-platform and/or plugin-less.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You need to be able to run a new process from a browser. There are a few ways to do this. I’ll show the JNLP way to do this.
Create a jnlp file as follows:
Create a jnlpTest.jar from the following:
With a Manifest:
Sign your JNLP jar:
place both the jar and jnlp file on a web server. Make sure the mime type JNLP is served as
application/x-java-jnlp-file.Reference for making a JNLP: http://java.dzone.com/articles/java-web-start-jnlp-hello
Now when a user clicks your jnlp link they will download the jar and be asked if it is ok to run. Running it will cause the explorer window to open. I know it’s not the best solution, but any solution will require asking the users permission to execute code on their machine.