PrintDocument object and printing text from a textbox

  • Thread starter Thread starter mivey4
  • Start date Start date
M

mivey4

I have a project for which I need to print the contents of a richtext
box to the printer. In VB6 this was a very simplified task but in
VB.NET it seems to be noted as a more complicated technique.

I have been programming for a short while but my strategy for learning
new tasks is to view the most simplified version of code available.
This way I can easily see the logic and proceed to complicate things
based upon my own learning however I haven't been able to find a very
very simple approach to doing this that works.

The only code that I have found that was excellent for describing the
process of utilizing the printer class in vb.net was located at:
http://www.startvbdotnet.com/controls/printdialog1.aspx

The only problem with the code is that it didn't pull the text from
the rich textbox as expected though it did print a blank sheet of
paper. I tried contacting the webmaster for the site to inquire if
there was a lack of information in the code provided but haven't
since received any reply. (Go Figure!)

If I could acquire working code that provided the use the printing
class at a very basic and simple level, that would be great.

Anyone have any code snippets that could assist me in this?

Please Help! :(
 
Nevermind,

The webmaster of the startvbdotnet kindly replied to my previous
request for the inquiry concerning the printing code and then
appropriately made an update to the code that provided the desired
results.

It is excellent simple code that will clarify the logic to the very
basic level. I would recommend it to anyone that has inquiries
concerning the print functions in vb.net.

The site again is
http://www.startvbdotnet.com/controls/printdialog1.aspx

:D
 
Back
Top