Batch Files

G

Guest

How do I make batch files run when I double-click them. My batch files
always want to open in notepad instead of running. If I right-click them,
then click on open, they will run. However, if I use the run command from
the start menu, the same thing happens--they open in notepad. This is a
problem because I need to run a batch file with a variable, but when I try
from the run command, it only opens with notepad. I am using Windopws XP
Home edition with SP2 included. If I right-click them, hit properties, there
is no option under the general tab to change the way the fiel opens. Any
help is appreciated.
 
N

Not Me

You can change that at: Control Panel/Folder Options/File Types/scroll
down to File Ext BAT and highlight it. Look down at the bottom of that
window and it should state that it is set to open with Notepad. Click
the "Advanced" button then change the action to "Open". Click OK and
Apply out of the window. You may have to restart to see the change.
Gene K
 
G

Guest

OK, I think I finally got it, although it was a little more complicated than
that. First of all .bat didn't come up when I first opened folder options,
so I had to act as though I were creating a new file extension. I then got a
message saying that the .bat extension was already associated with MSDOS
Batch files, did I want to unassociate it. I clicked no, and then .bat
appeared in the registered file extensions window. It was set to edit with
notepad; however the problem was that the default was set to edit, not open.
So from the advanced window I highlighted open, then clicked "Change
Default". That did it. Thanks for your help.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top