Results 1 to 3 of 3

Thread: RichTexBox

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jul 2000
    Location
    Europe, Lithuania
    Posts
    309

    RichTexBox

    hi,

    I have 6 rich text box'es. In all of them are inserted text and ole objects. How to print all data from these rich text box'es like this:

    "My text"
    richtextbox1 content
    "My text"
    richtextbox2 content
    richtextbox3 content
    richtextbox4 content
    richtextbox5 content
    richtextbox6 content

    I suggest to copy richtextbox1 content to memmory and then paste to new richtextbox, then copy other richtextbox's content and then paste.

    Any idies?

  2. #2
    Frenzied Member Microbasic's Avatar
    Join Date
    Mar 2001
    Posts
    1,402
    Your idea is the easiest. There are (MORE COMPLICATED) ways dealing with GDC and Bliting, but../

    VB Code:
    1. Dim MemVar As String
    2.     MemVar = RichTextBox1.TextRTF
    3.     RichTextBox1.TextRTF = RichTextBox1.TextRTF & RichTextBox2.TextRTF
    4.     RichTextBox1.TextRTF = RichTextBox1.TextRTF & RichTextBox3.TextRTF
    5.     RichTextBox1.TextRTF = RichTextBox1.TextRTF & RichTextBox4.TextRTF
    6.     RichTextBox1.TextRTF = RichTextBox1.TextRTF & RichTextBox5.TextRTF
    7.     RichTextBox1.TextRTF = RichTextBox1.TextRTF & RichTextBox6.TextRTF
    8.     RichTextBox1.SelLength = 0
    9.     RichTextBox1.SelPrint (Printer.hDC)
    10.     RichTextBox1.TextRTF = MemVar


    MicroBasic
    Dragon Shadow Trainer

    There is no good or evil in the world...only programmers and fools .

  3. #3

    Thread Starter
    Hyperactive Member
    Join Date
    Jul 2000
    Location
    Europe, Lithuania
    Posts
    309
    This works only with plain text. With ole object it not works...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width