I have a file which I’d like to print using system CMD. I used the command NET USE with the following syntax as mentioned below:
net use LPT1 \\machine name\printer name ..\file name.
While using this command I see nothing is the printing, help me.
The “net use” command just sort of gives the printer a name (in this case LPT1). The file parameter is useless there.
After you have mapped the printer with “net use” like in you example, you can redirect output to it, for example with
type 'file name' > lpt1: