General discussion

Locked

How to run java programme at startup

By VickyDicky ·
I want to start one of my programme which acts as "Server" at the startup of my server machine.
I tried it by adding this command in autoexec.bat
c:\java MyTest
I took care of classpath and path.After running this autoexec.bat just after theabove line i.e java MyTest I am getting message that "This programme cann't be run in Dos mode."
What I can do to solve this problem

This conversation is currently closed to new comments.

10 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

How to run java programme at startup

by Fossil In reply to How to run java programme ...

add the command lien to the registry under this key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run
It will be executed during the startup of windows.

You could also place it in the STARTUP folder.

Collapse -

How to run java programme at startup

by VickyDicky In reply to How to run java programme ...

Sorry to say but this ans will not help me b'cuz here we did not mentioned about my .class files name say "MyTest.class" which i want to execute at start up.

Collapse -

How to run java programme at startup

by srini_soma In reply to How to run java programme ...

using JToExe program you can make that file as exe and put it in startup folder. Otherwise, if possible to try to make windows shortcut and place in startup folder

Collapse -

How to run java programme at startup

by VickyDicky In reply to How to run java programme ...

Poster rated this answer

Collapse -

How to run java programme at startup

by okujava In reply to How to run java programme ...

make a batch file myjava.bat:

c:\java MyTest

and put it in the autostart programm group of windows

s.okujava

Collapse -

How to run java programme at startup

by okujava In reply to How to run java programme ...

a batch file is just a text file. u need only one line of text c:\java MyTest and save it as myjava.bat. take care, that u really rename it as .bat, not as .bat.txt (per default u see no extensions on windows). type dir in dosbox to check it

Collapse -

How to run java programme at startup

by VickyDicky In reply to How to run java programme ...

Yes it will work , but with this now i am facing one problem.
After starting m/c it is also running my java programme , but now i want is that, It should not open a new window. That means i want to run this java programe in the background

Collapse -

How to run java programme at startup

by okujava In reply to How to run java programme ...

if u want your prg to run in background, start it with javaw.exe...

s.okujava

Collapse -

How to run java programme at startup

by VickyDicky In reply to How to run java programme ...

Poster rated this answer

Collapse -

How to run java programme at startup

by VickyDicky In reply to How to run java programme ...

This question was closed by the author

Back to Web Development Forum
10 total posts (Page 1 of 1)  

Related Discussions

Related Forums