aspose file tools*
The moose likes General Computing and the fly likes Batch File Runner in Windows Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » General Computing
Bookmark "Batch File Runner in Windows" Watch "Batch File Runner in Windows" New topic
Author

Batch File Runner in Windows

Ashik Uzzaman
Ranch Hand

Joined: Jul 05, 2001
Posts: 2370

Do you know the name of the file that runs batch file in windows?
I need this because recently I got in trouble after creating a new file extension ".BAT" from Windows Explorer's Folder Options->File Types and told that TextPad will run the .BAT extension files. However, now I can't use the double-click approach to run say Tomcat startup.bat file because when I click it, TextPad opens the file so its not run. I have to open cmd now and from there type startup to run tomcat. The .BAT is not shown in the file types list and so at first I couldn't even change it.
To get rid of it. I tried uninstalling TextPad, creating another .BAT extension and tell to run it through WINNT/system32/cmd.exe. CMD.EXE then opens as expected a command wondow but does not run it.
So I think if I can get the name of the batch file runner, I can reassign that filename.exe (if exe at all ) to run .BAT again.
Any help?!?!


Ashik Uzzaman
Senior Member of Technical Staff, Salesforce.com, San Francisco, CA, USA.
Stan James
(instanceof Sidekick)
Ranch Hand

Joined: Jan 29, 2003
Posts: 8791
Wicked problem! Try cmd.exe if you can find it in the Windows directories.


A good question is never answered. It is not a bolt to be tightened into place but a seed to be planted and to bear more seed toward the hope of greening the landscape of the idea. John Ciardi
Randall Twede
Ranch Hand

Joined: Oct 21, 2000
Posts: 4347
    
    2

i have a .bat file to run tomcat. i open a dos window and type "tom" to run it though


SCJP
Visit my download page
Greg Messer
Greenhorn

Joined: May 15, 2003
Posts: 4
You need to use cmd.exe /C to run the batch file then terminate.
Greg
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Batch File Runner in Windows