Run vs. Command Prompt vs Elevated command prompt?

Page 1 of 2 12 LastLast

  1. Posts : 271
    Windows 10 Pro 64-bit
       #1

    Run vs. Command Prompt vs Elevated command prompt?


    Is there a rule of thumb to know which of the referenced you would use when entering a particular command or file name?

    Mark
      My Computer


  2. Posts : 4,224
    Windows 10
       #2

    Alas, I'm not aware of any such thing. It often comes down to figuring out what you want to do, finding the program(s) and/or command(s) necessary to accomplish such tasks, and then researching them one at a time to understand their runtime or execution requirements. Shoot! I'd love a resource like that myself. Recently, for example, it took me the better part of three days just to figure out which of the commands in the recently reissued Microsoft command line reference (PDF format) work within PowerShell and which ones require the command prompt, as recited in this May 14 blog post.
    HTH,
    --Ed--
      My Computers


  3. Posts : 271
    Windows 10 Pro 64-bit
    Thread Starter
       #3

    Thanks, that gives a lot of perspective to my periodic head scratchers!
      My Computer


  4. Posts : 1,097
    Windows 10 Home x64 Version 1809 (OS Build 17763.437)
       #4

    I'm not part of this conversation, but yes THANKS for the PDF link Ed. It's a more up to date and complete reference than the one I've been using.
      My Computer


  5. Posts : 13,987
    Win10 Pro and Home, Win11 Pro and Home, Win7, Linux Mint
       #5

    Because of some things I have to do I let PowerShell remain on the right-click of the Start button but also have Command Prompt [Administrator] pinned to my Taskbar. Can change the Start menu back to Command Prompt but haven't otherwise found how to have both there.
      My Computers


  6. Posts : 16,912
    Windows 10 Home x64 Version 22H2 Build 19045.4170
       #6

    Wiley Coyote said:
    It's a more up to date and complete reference than the one I've been using.
    Wiley,

    Yes, that pdf contains up-to-date & complete information on the Windows 10 versions of Defrag, Format & FSUtil.

    It also contains information on the server versions of many other commands.

    I am watching these and keeping my fingers crossed -
    Windows Command-Line: Backgrounder - TenForums
    Windows Command-Line: Backgrounder - MSDN

    Denis
    Last edited by Try3; 22 Jun 2018 at 11:44.
      My Computer


  7. Posts : 56,824
    Multi-boot Windows 10/11 - RTM, RP, Beta, and Insider
       #7

    Berton said:
    Because of some things I have to do I let PowerShell remain on the right-click of the Start button but also have Command Prompt [Administrator] pinned to my Taskbar. Can change the Start menu back to Command Prompt but haven't otherwise found how to have both there.
    You may already know, but typing CMD in Powershell gives a regular Command Prompt.

    Run vs. Command Prompt vs Elevated command prompt?-2018-06-22_13h00_14.png
      My Computers


  8. Posts : 1,097
    Windows 10 Home x64 Version 1809 (OS Build 17763.437)
       #8

    Try3 said:
    Wiley, … It also contains information on the server versions of many other commands. … Denis
    What you don't know is I'm doing good to effectively use Command Prompt, let alone Powershell or any other features.
      My Computer


  9. Posts : 16,912
    Windows 10 Home x64 Version 22H2 Build 19045.4170
       #9

    Wiley,

    Yes, I appreciate that. It is very difficult to get to grips with Windows commands without decent documentation or an onboard help system.

    What you can do for most commands is open a command prompt and type in the command followed by /? to see its own help info. So, for example, you can enter
    Code:
    dir /?
    and it will show you

    Code:
    Displays a list of files and subdirectories in a directory.
    DIR [drive:][path][filename] [/A[[:]attributes]] [/B] [/C] [/D] [/L] [/N]
      [/O[[:]sortorder]] [/P] [/Q] [/R] [/S] [/T[[:]timefield]] [/W] [/X] [/4]
      [drive:][path][filename]
                  Specifies drive, directory, and/or files to list.
      /A          Displays files with specified attributes.
      attributes   D  Directories                R  Read-only files
                   H  Hidden files               A  Files ready for archiving
                   S  System files               I  Not content indexed files
                   L  Reparse Points             -  Prefix meaning not
      /B          Uses bare format (no heading information or summary).
      /C          Display the thousand separator in file sizes.  This is the
                  default.  Use /-C to disable display of separator.
      /D          Same as wide but files are list sorted by column.
      /L          Uses lowercase.
      /N          New long list format where filenames are on the far right.
      /O          List by files in sorted order.
      sortorder    N  By name (alphabetic)       S  By size (smallest first)
                   E  By extension (alphabetic)  D  By date/time (oldest first)
                   G  Group directories first    -  Prefix to reverse order
      /P          Pauses after each screenful of information.
      /Q          Display the owner of the file.
      /R          Display alternate data streams of the file.
      /S          Displays files in specified directory and all subdirectories.
      /T          Controls which time field displayed or used for sorting
      timefield   C  Creation
                  A  Last Access
                  W  Last Written
      /W          Uses wide list format.
      /X          This displays the short names generated for non-8dot3 file
                  names.  The format is that of /N with the short name inserted
                  before the long name. If no short name is present, blanks are
                  displayed in its place.
      /4          Displays four-digit years
    Switches may be preset in the DIRCMD environment variable.  Override
    preset switches by prefixing any switch with - (hyphen)--for example, /-W.

    You can even save that information as a text file. You will come to think of this [later on] as easy but I'll be careful explaining it in case it is totally new to you.
    1 Decide on a convenient folder that you want to save the text file in. Somewhere convenient for you such as your desktop which might well be in C:\Users\YOURUSERNAME\Desktop - you'll need to use your own username for this to work i.e. the path to the folder in C:\Users\ that holds your own files.
    2 Decide what name you want to use for the text file. I just use the Command name itself e.g. Dir.txt but it is up to you.
    So enter this to save the help information in that folder
    Code:
    Dir /? >"C:\Users\YOURUSERNAME\Desktop\Dir.txt"

    Once you have that information saved you can study it at your leisure even though it probably seems overwhelming at first sight. That should at least give you enough information to ask questions about the command so that you can start using it.
    - As Ed said above, one of the great problems with Windows commands is that they have simply evolved over time and have no central philosophy governing their structure or use.
    - You can learn a particular command but cannot always apply the same principles to using other commands.
    It's all a bit of a mishmash.

    I hope these comments have been useful,
    Best of luck,
    Denis
      My Computer


  10. Posts : 13,987
    Win10 Pro and Home, Win11 Pro and Home, Win7, Linux Mint
       #10

    f14tomcat said:
    You may already know, but typing CMD in Powershell gives a regular Command Prompt.
    Yep. But clicking 1 icon takes me to where I can type, having Command Prompt on the Taskbar lets me bypass right-clicking the Start button then another click.
      My Computers


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 13:29.
Find Us




Windows 10 Forums