Sign in with
Sign up | Sign in
Your question
Solved

I would like to run a print command on the files specified in *.txt file.

Last response: in Windows 7
Share
May 1, 2012 1:43:58 PM

Hello,

I would like to run a print command on the files specified in *.txt file.

Command: "X:\path\application.exe /p"

File list in *txt file:
X:\folder1\folder2\document1.xcmd
X:\folder3\document2.xcmd
K:\folder7\document3.xcmd
ect...

I found something similar: for %%g in (*.xmcd) do "C:\path\mathcad.exe /p %%g


Thanks for the help in advance!
a b $ Windows 7
May 1, 2012 2:18:29 PM

niku7 said:
Hello,

I would like to run a print command on the files specified in *.txt file.

Command: "X:\path\application.exe /p"

File list in *txt file:
X:\folder1\folder2\document1.xcmd
X:\folder3\document2.xcmd
K:\folder7\document3.xcmd
ect...

I found something similar: for %%g in (*.xmcd) do "C:\path\mathcad.exe /p %%g


Thanks for the help in advance!

Pipe the file to lpt1
copy filename > lpt1
m
0
l
a c 228 $ Windows 7
May 1, 2012 5:09:23 PM

ksiemb said:
Pipe the file to lpt1
copy filename > lpt1


That won't work. They aren't text files, they are .xcmd files (mathcad) files.
m
0
l
Related resources

Best solution

a c 228 $ Windows 7
May 1, 2012 5:12:55 PM

This is the syntax for the for loop.

http://ss64.com/nt/for_f.html
Share
May 8, 2012 8:07:13 AM

Thanks all for the help. Solved
m
0
l
May 11, 2012 8:14:19 AM

Best answer selected by niku7.
m
0
l
a b $ Windows 7
May 11, 2012 8:47:27 AM

niku7 said:
Best answer selected by niku7.

nI would like to run a print command on the files specified in *.txt file.
n
nThey weren't text files !
m
0
l
!