Groups | Blog | Home
all groups > vb.net > february 2005 >

vb.net : Printing contents of an RichTextbox


Crouchie1998
2/14/2005 7:47:02 PM
There is a special forum setup for printing/report problems:

http://www.windowsforms.net/Forums/ShowForum.aspx?tabIndex=1&tabId=41&ForumID=5

Pug
2/14/2005 9:10:43 PM
Try this

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnwinforms/html/wnf_RichTextBox.asp

I've found it works ok but if you want to overlay the output on a bitmap you
have to also use 'sendmessage' to make the richtextbox transparent. With a
little work on the example code it doesn't even need to be onscreen.


[quoted text, click to view]

Pug
2/14/2005 9:12:48 PM
Or even

http://support.microsoft.com/kb/811401/EN-US/

which is better formatted.


[quoted text, click to view]

Urs Vogel
2/14/2005 9:57:32 PM
Hi



When printing coloured text from a RichTextbox, it turns out to be a quite
and timeconsuming job to position all differently coloured strings on the
Page with DrawString(). Is there a better method of achieving this, or are
there samples somewhere? Couldn't find anything on MSDN.



Thanks, Urs

Urs Vogel
2/14/2005 10:30:16 PM
Thanks Pug, that sounds reaonable.

"Pug" <not@this.address> schrieb im Newsbeitrag
news:42111464$0$33554$ed2619ec@ptn-nntp-reader03.plus.net...
[quoted text, click to view]

Herfried K. Wagner [MVP]
2/14/2005 10:31:31 PM
Urs,

"Urs Vogel" <uvogel@msn.com> schrieb:
[quoted text, click to view]

HOW TO: Print the Content of a RichTextBox by Using Microsoft Visual Basic
..NET
<URL:http://support.microsoft.com/?scid=kb;EN-US;811401>

Getting WYSIWYG Print Results from a .NET RichTextBox
<URL:http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnwinforms/html/wnf_RichTextBox.asp>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://dotnet.mvps.org/dotnet/faqs/>
AddThis Social Bookmark Button