Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Batch file switches

Batch file switches

Batch file switches

does anyone know of any websites that has a list of all the different batch file switches and what each one does.

i'm trying to run a batch file over SMS without the user being logged on, however, the program needs input from the user by selecting yes or no. is there a way i can have Yes as the default option in the batch file?

RE: Batch file switches

I wonder if
ECHO "Y" | you_batch_file_name
can help.

RE: Batch file switches

well, each command has its own set of switches and cant be assumed the same switch means the same for another command. and some require the switch in the middle of the command rather than at the end. Is there a command in particular that you are interested in? Win2000 and XP have very good help files available via the F1. Check out http://www.robvanderwoude.com/index.html for tips and tricks
in batch files. very helpful site.
if your batch file calls an .MSI you can put a switch that runs it silent.

RE: Batch file switches

What Batch File means to you.

If it is command cmd.exe, than see in help.

If it is somebody's Batch file than it has to handle input parameters passed to it.

There is no way to run Batch file if file does not handle passed parameters.

Yes, there is the way to have Yes as the default option.
Developer needs to create the solution.
Here is quick one.
If program is called and parameter is not passed than programm logic should consider it as YES.

Hope it helps.


RE: Batch file switches

I said:
...There is no way to run Batch file if file does not handle passed parameters...

In context of passing parameters, I mean it is nonsense to pass parameter to batch file if file does not handle passed parameters.


Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close