Sending command to a single in a text file
Posted: 22 May 2021 13:44
Hello,
Does anybody know to to single multiple commands with results to a single line to text file in windows 10 cmd.
What I want to do is send the name of the hostname of the computer and the date
The command are Hostname & date /t >> test.file.
This command only send the date, but the Hostname. I have tried Hostname & date /t without sending the output to a file and I notice that it displays
Hostname
Date
What I want is Hostname Date in a single line then send it to the textfile as a single line not two lines.
Is this possible?
Thanks
Does anybody know to to single multiple commands with results to a single line to text file in windows 10 cmd.
What I want to do is send the name of the hostname of the computer and the date
The command are Hostname & date /t >> test.file.
This command only send the date, but the Hostname. I have tried Hostname & date /t without sending the output to a file and I notice that it displays
Hostname
Date
What I want is Hostname Date in a single line then send it to the textfile as a single line not two lines.
Is this possible?
Thanks