| || |
Join Date: Apr 2008
Re: How to create a Batch file
You need to follow few steps.
- Open a notepad file.
start/d "C:\Program Files\Mozilla Firefox" firefox.exe
start /d "C:\Program Files\Microsoft Office\Office12" EXCEL.EXE
- There will be different path for Windows Xp and Vista.Window Xp uses MS Office as extension for opening the file (Office 2007 is used in the example).
- Where start tells Windows to open a separate window to run the specified program.
- The /d switch tells start command the path of the program. For starting Excel and Firefox, notice that the paths are in quotes, which is needed when there is a space in the file path.
- Now it's great that all two programs are open.
- But if you need to open an website in Mozilla firefox For example www.yahoo.com than the commands go as this
start/d "C:\Program Files\Mozilla Firefox" firefox.exe www.yahoo.com
- This way you can open any number of files/application.
- Most important don?t save the file with extension as .txt save it as .batthan only the batch file will be created.