Is this even possible? That is what would be done from the Java code of the program. OS Windows.
2 answers
Perhaps, and easily. Open the system registry (like this, for example: Read / write to Windows registry using Java ):
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Run - autorun only the current user, or
HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Run - shared autorun (requires administrative privileges),
and write there a string variable with an arbitrary name (for example, "MyProggie_Autorun") and the command to be executed as a value. In your case, the jar launch command.
|
one of the options is to make a service for jar-nickname, for example, using WinSW
|