PRINT TEXT on thermal printer on parallel port(LPT1)

Hi,
I have tried to print a text file through an asp page
for example, the text to print:

********************************
Package Details
*********************************
Item No:1
Product ID:
Sales Order ID:2542122

I want to print this on a thermal printer how do i do that?
i used the following code but it doesnt do anything,i put the text in a .txt file

Private Sub PrintFile(ByVal FileName As String)
        Dim si As New ProcessStartInfo
        With si
            .FileName = System.Environment.GetEnvironmentVariable("COMSPEC")
            .Arguments = String.Format("/C print /D:LPT1", FileName)
            .UseShellExecute = False
            .CreateNoWindow = True
        End With
        Process.Start(si)
        si = Nothing
 End Sub
calorisplanitiaAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

PockyMasterCommented:
IIS will probably not allow you to access the shell, without proper authentication
0
PockyMasterCommented:
But you can always just put the files somewhere, and let another process (not ASP) but e.g. Forms app monitor a folder and pick up the files for you.
0
calorisplanitiaAuthor Commented:
hi
I need to know the syntax for thermal printer e.g. this text prints:

N
OD10
q812
Q1218,24
D15
ZB
LO0,147,800,4
LO0,401,800,4
LO0,746,800,4
A35,9,0,2,1,1,N,"From:"
A35,28,0,2,1,1,N,"Microsoft"
A35,48,0,2,1,1,N,""
A35,68,0,2,1,1,N," MORGAN PARK"

Above text when sent to a thermal printer using the code PrintFile function, prints :
From:
Microsoft

Morgan Park

so i need to know if any body know the syntax as plain text file doesnt print
0
Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

PockyMasterCommented:
You are using a Zebra printer right?
0
calorisplanitiaAuthor Commented:
yes
0
PockyMasterCommented:
If you are looking for a protocol specification, didn't you get one with your printer? or otherwise have a look at the zebra website
0
calorisplanitiaAuthor Commented:
ok thanks,
but i cant find any on their website
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
calorisplanitiaAuthor Commented:
Hi Pocky Master
that link helped
but iam struck with the printfile function isnt doing anything, i have created an application in vb.net which monitors a folder & prints it. But the function isnt printing anything, even a test file.
however it prints fine through the DOS prompt
Dont know what to do  i am struck again.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic.NET

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.