printing with GDI+

  • 12 years ago

    HI, every1 I making a control with several textboxes and I need to print them. I print without any problem with GDI+ but the problem come true when the I have text more then 1 row. How it is possiblem to make two rows from one textbox and draw them with GDI+ in printdocument. Thank You.

  • 12 years ago

    You can print anything you want with a PrintDocument.  You simply handle the PrintPage event and pass the string you want to print to e.Graphics.DrawString.  That method is overloaded so you can control all sorts of aspects of how the printing is done.

  • 12 years ago

    Yes I know that but the problem is that if my string from my textbox is longer then one row then printdocument it's not braking in two rows but just leaving in one row and then my complet string its not printed because it's hiding out of paper. Thank You.

Post a reply

Enter your message below

Sign in or Join us (it's free).


Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Perl - The only language that looks the same before and after RSA encryption.” - Keith Bostic