I always need to run

java -jar e:\abc.jar --boundHost -all- 

in the command promt.

So I have to Run and type cmd , open the DOS prompt then I type/paste above command and press enter.

Can I make a executable file file on desktop so I can just double click on that file to run the command?

link|improve this question

45% accept rate
1  
It's not a DOS prompt and never has been, note. – JdeBP Jul 29 '11 at 14:16
feedback

1 Answer

up vote 2 down vote accepted

Just write that in a text file then rename the extension to .bat

link|improve this answer
you mean I just need to put this java -jar e:\abc.jar --boundHost -all-1 in a .bat file – metal gear solid Jul 29 '11 at 8:32
True, there is no special command for showing 'cmd' first. Just write your 'code' in new text file & save it with .bat extension. – Adam RichardSon Jul 29 '11 at 8:33
yes, @metalgear – Sathya Jul 29 '11 at 9:11
… or to .CMD. – JdeBP Jul 29 '11 at 14:18
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.