Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.



Windows 7: Shortcut with 2 commands

05 Mar 2013   #1

Windows 7 Home Premium 64
 
 
Shortcut with 2 commands

Is it possible to run more than one batch file command in a shortcut? I have tried a couple of thins and they did not work.

Example:
Code:
cmd /c start program
cmd /c start another program


My System SpecsSystem Spec
.

05 Mar 2013   #2

Win7 Home Premium 64x
 
 

I don't think you can put two commands in one shortcut, but you could write a simple batch file to call both programs and shortcut to that batch file.

Or if I'm not following right, are you saying you can't write a batch file that calls two programs?

Either way, check out this thread: Batch Files - Start Multiple Programs At Once
My System SpecsSystem Spec
05 Mar 2013   #3

Windows 7 Home Premium 64
 
 

I didn't think it was possible. My goal was to keep the command window out of view. I tried using a shortcut set to open the window minimized, but that 2 files as you indicated. Oh well... thanks anyway.
My System SpecsSystem Spec
.


05 Mar 2013   #4

Windows 8 Core X64
 
 

You can & them together perhaps:

cmd /c start program & start another program
My System SpecsSystem Spec
05 Mar 2013   #5

Windows 7 Home Premium 64
 
 

Quote   Quote: Originally Posted by Ztruker View Post
You can & them together perhaps:

cmd /c start program & start another program
Never thought of that, IT WORKS, thanks....
My System SpecsSystem Spec
05 Mar 2013   #6

Windows 7 Pro-x64
 
 

Quote:
cmd /c start program & start another program
You can use multiple commands separated by the command separator && for string, but you must enclose them in quotation marks (for example, "command&&command&&command").

You can run a batch file that will execute as many programs as you want. Use the Echo Off to keep the batch file "silent". If you must use the CMD command, use /k and /q parameters to run and continue and echo off respectively.

Forgot to add the link to the CMD syntax. http://technet.microsoft.com/en-us/l.../bb490880.aspx
My System SpecsSystem Spec
05 Mar 2013   #7

Windows 7 Home Premium 64
 
 

The reason I was avoiding "/k" is that the command window stays open.
My System SpecsSystem Spec
Reply

 Shortcut with 2 commands





Thread Tools



Similar help and support threads for2: Shortcut with 2 commands
Thread Forum
Run Commands for Windows 7 Tutorials
How to do global commands General Discussion
Help Automatating CMD Commands General Discussion
Solved Bat commands.. General Discussion
Solved Windows Run Commands General Discussion
Run commands remembered ? General Discussion
Shortcut commands? Gaming

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 02:10 PM.
Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App
  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33