We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now


Windows Cmd Prompt How to make two actions happen

Medium Priority
Last Modified: 2012-05-06
IM and trying to write a simple syntax via windows cmd prompt to perform two actions....

C:\Program Files\Microsoft Office\Office>FOR /R \\cinhnf05.tsg.ge.com\ec_dev_sdaviationedrb\DOC_Files\50000 %G IN (*.doc) DO set filePath=%G and excel.exe /r Test_AutoRun4.xls

The for-loop works great, the syntax is perfect except I want to DO two things.  I don't know how to make the command window see two commands after the DO.  "and" did not work for me.

Please Help... Thanks

Watch Question


Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.


Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.