HELP creating a .bat file

Trying to make C:\Program Files\Symantec\BackUp Exec>bemcmd -o503 a .bat file please help.
ManieyaK_Citrix Systems / Network AdminAsked:
Who is Participating?
Lee W, MVPConnect With a Mentor Technology and Business Process AdvisorCommented:
Create a text file with a .cmd extension and put the following lines in it:

@echo off
"C:\Program Files\Symantec\BackUp Exec\bemcmd" -o503

Open in new window

(The Echo off is generally unnecessary, but I put it in almost all my batch files)

Note: you need to save the batch file in a folder that's included in the PATH environment variable - any folder should work so long as it's in the path.  (I usually use C:\Windows\System32).

To see what folders are in your path, at a command prompt, type echo %path%
David KrollCommented:
Just create a text file, name it whatever you want.bat, edit and put this line in.

C:\Program Files\Symantec\BackUp Exec\bemcmd -o503
ManieyaK_Citrix Systems / Network AdminAuthor Commented:
Are the " marks necessary?
Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

ManieyaK_Citrix Systems / Network AdminAuthor Commented:

Could you provide an example to your previous post please?

To see what folders are in your path, at a command prompt, type echo %path%
Lee W, MVPTechnology and Business Process AdvisorCommented:
Yes, the quotes are necessary else the batch file thinks the command is
C:\Program is the command and Files\Symantec\BackUp Exec\bemcmd are parameters.

echo path
Lionel MMSmall Business IT ConsultantCommented:
I suggest you add a few lines. Any comment lines to help you remember what you were trying to do or when can be inserted as long as you place rem or Rem or REM at the start of the line. I also suggest you use the Start command that way the program starts and the cmd exe can close. And just as good practice I also suggest you include the Exit command when using batch files, not required just suggested. Just copy the attached file and either double click on it from Windows explore or run it from a dos window. Just rename it from test.txt to test.bat

@Echo Off
Rem Created by
Rem Used to start
Rem Date and date changes made

Start "C:\Program Files\Symantec\BackUp Exec\bemcmd" -o503
ManieyaK_Citrix Systems / Network AdminAuthor Commented:
leew -

So why no " around -o503?
just trying to figure this out for future reference having a hard time crasping the concept.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.