What is "more?" when typing '(' in cmd?

Page 2 of 2 FirstFirst 12

  1. Posts : 17,545
    Windows 10 Pro x64 EN-GB
       #11

    Anak said:
    Kari, that is a beautiful example on how the More? cmd is used.

    Can I assume that if I see the "?" mark after other commands, the interpreter is asking for more input?
    No :).

    But if you see More ?, it means the command is incomplete, Windows does not understand it.

    I notice that I did explain this quite poorly, so here's a bit more information.

    You can give several commands in one command line sentence as far as the commands are separated with an ampersand (&) and put within the parenthesis. This is useful in batch files, especially when doing FOR ... DO loops.

    Following command sentence would first create a folder called D:\TARGET, then copy all PDF files starting with the letter B from folder E:\TEST to D:\TARGET and finally show message "Selected files in E:\TEST copied to D:\TARGET":

    (MD D:\TARGET & COPY E:\TEST\B*.pdf D:\TARGET & ECHO Selected files in E:\TEST copied to D:\TARGET)

    Notice the ampersand (&) signs between the commands, command sentence within the parenthesis.

    The output in command prompt window would look like this:
    What is "more?" when typing '(' in cmd?-2013-07-29_160004.png

    Kari
    Last edited by Kari; 29 Jul 2013 at 09:20. Reason: Serious typo fixed
      My Computer


  2. Posts : 5,605
    Originally Win 7 Hm Prem x64 Ver 6.1.7600 Build 7601-SP1 | Upgraded to Windows 10 December 14, 2019
       #12

    Thanks for More? information on the subject.
    Unfortunately I've let my command skills wither to the point that I would have to burn some serious midnight oil to get back into it, but I've always enjoyed working with the command prompt.

    I saved vanderwoude's link.
      My Computer


  3. Posts : 17,545
    Windows 10 Pro x64 EN-GB
       #13

    No probs, Anak :).

    The command line and batching / scripting options in Windows cover a lot more, can do a lot more than an average user or even quite geeky user usually knows, not to mention how complex things you can do with Windows PowerShell.

    With modern operating systems it is of course possible to use the PC almost solely by pointing and clicking but IMO it is worth for every advanced Windows user to learn command line and PowerShell.

    Just my 2 Euro cents...

    Kari
      My Computer


  4. Posts : 126
    Windows 7 Professional x64
    Thread Starter
       #14

    So basically you can run multiple commands like that... interesting
      My Computer


  5. Posts : 17,545
    Windows 10 Pro x64 EN-GB
       #15

    M4dn3ss said:
    So basically you can run multiple commands like that... interesting
    Yes. Using the opening parenthesis alone you can also input multiple commands into a buffer, to be executed all one after another only when the closing parenthesis is given.

    An example. Try this, input the characters and commands in command prompt as told here:
    • Type ( and hit Enter
      • This starts a multiple command sentence and asks more information
    • Type dir C: and hit Enter
      • No closing parenthesis ergo system asks more
    • Type Echo This was an example of multiple commands in one command sentence and hit Enter
      • Again, no closing parenthesis, system asks more
    • Type ) and hit Enter
      • Command sentence finished with closing parenthesis, being ready to be executed. As instructed, the system shows folder listing and thereafter the text "This was an example of multiple commands in one command sentence"

    The above example in command prompt window would look like this:
    What is "more?" when typing '(' in cmd?-2013-07-30_120116.png
    Kari
    Last edited by Kari; 30 Jul 2013 at 12:04. Reason: Fixed some annoying typos
      My Computer


 
Page 2 of 2 FirstFirst 12

  Related Discussions
Our Sites
Site Links
About 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 07:03.
Find Us