(Solved) - bat files(9 posts)
Here is a .bat file that displays the days of the week...
To print the output, you could pipe the output to a printer, e.g., C:\>dow.bat | LPT1:
or you could send the output to a .txt file and then print that, e.g., with Notepad: C:\dow.bat > dow.txt
Hope this helps.
Is it really that simple, you want to see it on your display and print it? If so, just create a TXT file, actually don't even need do that. Open Notepad, type in what you want and then Print... or do the above post?
We must be missing something here?
What do you really want?
@dysert has a good start. Since most printers now days are connected to a USB port not an LPT: port, in order to send the print from DOS you would have to execute a command such as
NET USE LPT1: \\[Computer Name]\[Printer name] /PERSISTENT:YES
The parameters are dependent on how your printer is attached or shared.
Still nt understanding what you are trying to do and why. Sounds like it must be some kind of meaningless class assignment.
Hi-Thx for responding-Im just trying to figure out how things work in batch files and want to use CHOICE 1-7 for the days of the week-i had %monday% instead of quotes "monday"
I tried using
choose= set /m choice="please enter a number from the following:"
IF Not :"%choose%"=="" set
Im guessing the syntax is wrong as choice isnt recognized as internal or external command
This topic has been closed to new replies.