Question

We have a big Java Swing application and with it comes a jar called CreateShortcut that creates a vbscript .wsf who does the job of creating the shortcuts for the system and also put it on the on the start menu and runs it with

Runtime.getRuntime()
      .exec((new StringBuilder("cmd /c \"")).append(getFileWsf()).append("\"").toString())
      .waitFor();

But it always ask for permission to run it from the operational system, and that is scaring a lot of clients.

I would like to know if there's a way of doing it without asking for the permission with the .wsf or maybe just do it on the jar itself with java. Thank you in advance.

Was it helpful?

Solution

Apparently this is what I was looking for:

http://alumnus.caltech.edu/~jimmc/jshortcut/
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top