Printing a File..

  • Thread starter Thread starter VJ
  • Start date Start date
V

VJ

I am able to print to File, which I am doing fine in our Program now. I want
to be able to take this file and Print to a printer.

Vijay
 
Vijay,

Do you have a library that will do it already, or do you have to "draw"
the contents to the printer yourself? If the answer is the latter, then you
should check out the PrintDocument class in the System.Drawing.Printing
namespace.

Hope this helps.
 
I have printed to the File. The file physically exists in a Windows Folder.
I want to be able to open and print this file from my program

Vijay

Nicholas Paldino said:
Vijay,

Do you have a library that will do it already, or do you have to "draw"
the contents to the printer yourself? If the answer is the latter, then
you should check out the PrintDocument class in the
System.Drawing.Printing namespace.

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

VJ said:
I am able to print to File, which I am doing fine in our Program now. I
want to be able to take this file and Print to a printer.

Vijay
 
VJ,

Is the file a custom format, or is it handled by another application?
If so, what kind of file, and what application is it?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

VJ said:
I have printed to the File. The file physically exists in a Windows Folder.
I want to be able to open and print this file from my program

Vijay

Nicholas Paldino said:
Vijay,

Do you have a library that will do it already, or do you have to
"draw" the contents to the printer yourself? If the answer is the
latter, then you should check out the PrintDocument class in the
System.Drawing.Printing namespace.

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

VJ said:
I am able to print to File, which I am doing fine in our Program now. I
want to be able to take this file and Print to a printer.

Vijay
 
Nicholas,

Its a Jpeg file, with one ore more pages. It is generatred by our porgram,
using classes in System.Drawing.Printing namespace.

Vijay


Nicholas Paldino said:
VJ,

Is the file a custom format, or is it handled by another application?
If so, what kind of file, and what application is it?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

VJ said:
I have printed to the File. The file physically exists in a Windows
Folder. I want to be able to open and print this file from my program

Vijay

Nicholas Paldino said:
Vijay,

Do you have a library that will do it already, or do you have to
"draw" the contents to the printer yourself? If the answer is the
latter, then you should check out the PrintDocument class in the
System.Drawing.Printing namespace.

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

I am able to print to File, which I am doing fine in our Program now. I
want to be able to take this file and Print to a printer.

Vijay
 
Vijay,

If you are doing that, you can use the PrintDocument class. When the
Print event is called, your handler should load the JPG and then call the
DrawImage method on the Graphics instance passed to your event handler.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

VJ said:
Nicholas,

Its a Jpeg file, with one ore more pages. It is generatred by our porgram,
using classes in System.Drawing.Printing namespace.

Vijay


Nicholas Paldino said:
VJ,

Is the file a custom format, or is it handled by another application?
If so, what kind of file, and what application is it?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

VJ said:
I have printed to the File. The file physically exists in a Windows
Folder. I want to be able to open and print this file from my program

Vijay

in message Vijay,

Do you have a library that will do it already, or do you have to
"draw" the contents to the printer yourself? If the answer is the
latter, then you should check out the PrintDocument class in the
System.Drawing.Printing namespace.

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

I am able to print to File, which I am doing fine in our Program now. I
want to be able to take this file and Print to a printer.

Vijay
 
Ok I have tried that.. Let me be more specific in my problem...

My Print, Print To File, Preview all work fine with Regular printers. .I am
having trouble printing to a mini printer Zebra RW420. When I use my print
as described earlier, or as you have suggested it prints Junk characters. It
works, if I do a print to file and go to that file and open it in Paint
program, Microsoft Image Editing software or any Windows program, I try to
print, the file prints properly. When I do the same thing as a Print
command, it fails. I have spoken to the Zebra tech support and they are
clueless.. they are like .NET what?.. so I was trying to see if I can
replicate like a shell print command that I can execute on the file. Anyway
I can do it.. or I should be able to prove that there this is a printer
setting problem

Thanks
Vijay

Nicholas Paldino said:
Vijay,

If you are doing that, you can use the PrintDocument class. When the
Print event is called, your handler should load the JPG and then call the
DrawImage method on the Graphics instance passed to your event handler.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

VJ said:
Nicholas,

Its a Jpeg file, with one ore more pages. It is generatred by our
porgram, using classes in System.Drawing.Printing namespace.

Vijay


Nicholas Paldino said:
VJ,

Is the file a custom format, or is it handled by another application?
If so, what kind of file, and what application is it?


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

I have printed to the File. The file physically exists in a Windows
Folder. I want to be able to open and print this file from my program

Vijay

"Nicholas Paldino [.NET/C# MVP]" <[email protected]>
wrote in message Vijay,

Do you have a library that will do it already, or do you have to
"draw" the contents to the printer yourself? If the answer is the
latter, then you should check out the PrintDocument class in the
System.Drawing.Printing namespace.

Hope this helps.


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

I am able to print to File, which I am doing fine in our Program now.
I want to be able to take this file and Print to a printer.

Vijay
 
Back
Top