Page 2 of 2 FirstFirst 12
  1.    30 Apr 2017 #11
    Join Date : Apr 2017
    Posts : 8,861
    windows 10 professional version 1607 build 14393.969 64 bit

    Is the goal to have the quickest link to powershell? Consider pinning the icon to the task bar like browsers, file explorer etc.
      My ComputerSystem Spec
  2.    30 Apr 2017 #12
    Join Date : Oct 2014
    Arnold, MD
    Posts : 29,071
    Triple boot - Win 10 Pro, Win 10 Pro Insider (2) - (and a sprinkling of VMs)

    Quote Originally Posted by Mystere View Post
    If you put those commands in a .cmd (or even .bat) file, then execute them, they will work because Powershell will execute .cmd and .bat files with cmd.exe

    If you want to type them into the shell natively, then just type cmd and you're in a cmd prompt within Powershell.
    Thanks for emphasizing what I posted in #8.
      My ComputersSystem Spec
  3.    01 May 2017 #13
    Join Date : Aug 2014
    Australia, Adelaide
    Posts : 1,561
    W7 Ultimate SP1 (64 bit), LM 18.2 MATE (64 bit), W10 Home (64 bit)

    Quote Originally Posted by Pyprohly View Post
    Id say this is a good thing anyway, but maybe you say this because you often see people write and share PowerShell commands in their most verbose form. PowerShell lines can often be reduced quite a lot. You can be as verbose or as implicit as you want.
    ...
    Additionally, it is expected youd use tab completion and never fully type out commands.
    I suspect that you are correct.

    When I was studying W2K8, we did some PowerShell exercises.
    In one of the exercises, we had to add a new user/password/group to AD and the PS command was enormous.

    Verbose is good in scripts, because it:
    • Doesn't matter how long it takes type it in correctly
    • Makes it easier to figure out what the script does at a later date


    I copy complicated CLI commands from the web examples (in both Linux & Windows) when I need to use them.

    I wouldn't have guessed that those two PS commands were identical (if you hadn't made it obvious that they were).
      My ComputerSystem Spec

 
Page 2 of 2 FirstFirst 12


Similar Threads
Thread Forum
Solved Context menu now has "Powershell" instead of "Command Prompt"
So I updated to the CU over a week ago, and I noticed an odd change. The "Open command prompt here" option in the shift+right-click context menu has been replaced by "Open Windows Powershell here" instead. Powershell does not work with the apps I...
General Support
Drive missing in "This PC" but still works fine in command prompt
This problem is usually fixed by slow solutions such as restarting my PC. But I run into this every day, so I need a better solution. I have a Buffalo NAS (network hard drive). I have to keep that at Auto-on mode because it's noisy. So everytime I...
Drivers and Hardware
[How-To] Context menu "Open elevated Command Prompt Here" without UAC
1. Create a newTask named OpenCmdHereAsAdminNoUAC and activate "Run with the highest privileges" 2. Go to the Actions Tab, create a new Action "Start a Program" choose "C:\Windows\System32\cmd.exe" and set the Working Directory (Start in) to...
Customization
How to open the "Custom sizing options" window using command line?
I want to use the command line to open the "Custom sizing options" window in Windows 10, please view the image, thank you. 99228
Customization
"Open with..." dialog command not working.
When you right click any file, you can see the Open with... dialog. When I click it, nothing happens. :( :sleepy: I kept on waiting but the Open with window is still not popping out of my screen. :chuckle: Well I tried this solution that was...
Software and Apps
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 21:12.
Find Us
Twitter Facebook Google+ Ten Forums iOS App Ten Forums Android App



Windows 10 Forums