I created a Java program that I want to automatically run when I turn on my PC, so I made the following run.bat and put it in Window's Startup folder:
start javaw -jar "Program.jar" "some default arg"
When I double click it myself, everything works.
But after I restart my PC, I always get an ArrayIndexOutBoundsException for the line that accesses args[0].
Why is this happening?