I have a jar file called test.jar that I run with a script package from the same folder. Here's the batch code:
java -jar test.jar pause
The bank itself works without problems, and I can run it just fine. However, if I try to run the batch file as an administrator (by right-clicking on it and selecting "Run as administrator"), I get the following error:
Error: Unable to access jarfile test.jar
I am using Windows 8.1, but this also happened on a machine running Windows 7. What can I do to run this as an administrator?
source share