PowerTip: Use PowerShell to Automate Commands with DiskPart

PowerTip: Use PowerShell to Automate Commands with DiskPart

  • Comments 1
  • Likes

Summary: Learn how to easily automate commands by using DiskPart.exe.

Hey, Scripting Guy! Question How can I use Windows PowerShell to automatically run DiskPart.exe commands that I use to make bootable keys?

Hey, Scripting Guy! Answer Store the commands you use in DiskPart.exe in a text file (runme.txt in this example), and run them automatically by adding the /s parameter:

DISKPART.EXE /s runme.txt

Note   You must run DiskPart.exe as Administrator.

Your comment has been posted.   Close
Thank you, your comment requires moderation so it may take a while to appear.   Close
Leave a Comment