I’m writing a batch script that will open diskpart and write some code from a file to it, then save the output to an another file, all in the same directory.
This is my current code:
@echo off
diskpart /s code.txt > output.txt
pause
code.txt file contains list volume
output.txt file is created, but is empty, no idea why.
I tried using >>
instead of >
but it also doesn’t seem to work.
Can someone help please?
New contributor
MORVILxv is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
8