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
rdwray

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
Thorsen

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
rdwray

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
Ztruker

Windows 8.1 Pro X64
 
 

You can & them together perhaps:

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

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
carwiz

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
rdwray

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
Thread Forum
Custom 'Desktop (create shortcut)' Remove .fileextension - Shortcut
Hi guys n girls, I have for ever got sick and tired of right click -> open Send to Menu and creating a Desktop Shortcut for a file or app....then needing to go to the Desktop right click the newly made shortcut and then removing the trailing file extension, dash and words shortcut in brackets....
Customization
Bat commands..
Okay im trying to make a mini-fool for my friend :D And i want to my friend donot see the bat file Is this the code to he cant see it? attrib +h %0 Thanks. - kuchiyo
General Discussion
Commands not recognized
Hello, I've a problem, why all the commands I type into CMD are not recognized by windows? traceroute, ping, nslookup, etc... 'nslookup' is not recognized as an internal or external command, operable program or batch file. my PATH is C:\Program Files;C:\Winnt;C:\Winnt\System32
Software
Run commands remembered ?
Is there any way to get the Run box to remember commands ? For instance msconfig, regedit. Each time the Run command box is opened all previous entries are gone and it's blank. Small thing maybe, but when I'm constantly fiddling it saves typing.:rolleyes:
General Discussion
Commands in Windows 7
Commands in Windows 7 If you like to work with Command Prompt commands here some new or Modified commands uses in Windows 7. For a more detailed explanation of all commands in Windows below, see: Command-Line Reference Windows Command Reference
Tutorials
Cmd line commands
Hi there First post on this forum :) I have an issue with the command line of Windows 7. Whenever I type in the shutdown command in an elevated console, I simply get a list of available arguments. Similar to typing shutdown /? Any advice would be much appreciated
General Discussion

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 05:02.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App