Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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?

share|improve this question
1  
It's not a DOS prompt and never has been, note. –  JdeBP Jul 29 '11 at 14:16
add comment

1 Answer 1

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

share|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
    
it doesn't work. it just oped dos window once –  metal gear solid Oct 11 '12 at 9:02
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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