E
ElMudo
Guest
Hi everyone, and thanks for taking the time to answer.
I'm pretty new to C#, so I'll need a bit of clarification on the steps to follow to control a printer with C#.
Well, I've searched google and MSDN widely and I found many articles about this subject, but none of them helped me to clear out the steps to control a USB printer (printing, sending data to it or whatever controlling a printer allows).
I have a HP deskjet 1050 printer and I'm using Windows 7 64 bit and Visual studio 2010.
So, what are the steps to control a printer? What objects I need to create? What methods or properties I need to use?
Let's for example say I'm working on a notepad file and I have my C# program. I want it to read the file and print it, or, let me select a printer and print the file on that one, or, just start the image acquisition process (scanner) and so on. Sorry for being so general and unprecise, but I really don't know what the library System.Drawing.Printing can and can't do and what are its limits.
I found various results, but I can't post the links because it says I have not verified the account, so I'll try a workaround:
<p><a href="http://support.microsoft.com/kb/322091">http://support.microsoft.com/kb/322091<br /></a><a href="How to get the list of all printers in computer" target="_blank">USB general article</a></p><p><a href="http://support.microsoft.com/kb/322091"></a><a href="How to get the list of all printers in computer" target="_blank">Where I discovered about Drawing Library</a><br /><a href="Content Removed (Windows)" target="_blank">BIDI Communications, probably for making your own driver<br /></a><a href="Printing in C#" target="_blank">Until now, the most useful article I found</a><br /><br /></p>
Try to copy/paste those...
Well, I still need a guideline on how to do it, since these article confused me a bit. They seem to take as source of the document to print sometimes office built in APIs, sometimes documents selected with a OpenFileDialog, sometime other things. Sometimes they set all the printing settings with variables, sometimes they just go print. Sometimes they suggest you do the work of detecting USB printers, sometimes they suggest you to use Win32 Spooler, and so on....
I'm a bit confused, a bit of help would be greatly appreciate.
Continue reading...
I'm pretty new to C#, so I'll need a bit of clarification on the steps to follow to control a printer with C#.
Well, I've searched google and MSDN widely and I found many articles about this subject, but none of them helped me to clear out the steps to control a USB printer (printing, sending data to it or whatever controlling a printer allows).
I have a HP deskjet 1050 printer and I'm using Windows 7 64 bit and Visual studio 2010.
So, what are the steps to control a printer? What objects I need to create? What methods or properties I need to use?
Let's for example say I'm working on a notepad file and I have my C# program. I want it to read the file and print it, or, let me select a printer and print the file on that one, or, just start the image acquisition process (scanner) and so on. Sorry for being so general and unprecise, but I really don't know what the library System.Drawing.Printing can and can't do and what are its limits.
I found various results, but I can't post the links because it says I have not verified the account, so I'll try a workaround:
<p><a href="http://support.microsoft.com/kb/322091">http://support.microsoft.com/kb/322091<br /></a><a href="How to get the list of all printers in computer" target="_blank">USB general article</a></p><p><a href="http://support.microsoft.com/kb/322091"></a><a href="How to get the list of all printers in computer" target="_blank">Where I discovered about Drawing Library</a><br /><a href="Content Removed (Windows)" target="_blank">BIDI Communications, probably for making your own driver<br /></a><a href="Printing in C#" target="_blank">Until now, the most useful article I found</a><br /><br /></p>
Try to copy/paste those...
Well, I still need a guideline on how to do it, since these article confused me a bit. They seem to take as source of the document to print sometimes office built in APIs, sometimes documents selected with a OpenFileDialog, sometime other things. Sometimes they set all the printing settings with variables, sometimes they just go print. Sometimes they suggest you do the work of detecting USB printers, sometimes they suggest you to use Win32 Spooler, and so on....
I'm a bit confused, a bit of help would be greatly appreciate.
Continue reading...