Results 1 to 5 of 5

Thread: Question on RichTextBox

  1. #1

    Thread Starter
    New Member
    Join Date
    May 2000
    Posts
    7

    Question

    I am making a telnet client which uses the rtf box to get the text from the server.

    What I need to know is how to make it scroll down as new text is sent in..as it is now everytime new text is sent to me it defaults to the top of the scrollback buffer.

    How can I make it default to the bottom of the scrollback buffer so I can read what is coming in?

    Thanks again, prolly something I am just overlooking.

    Alan

  2. #2
    New Member
    Join Date
    Jun 2000
    Location
    Indy, Indiana
    Posts
    2

    Arrow this is what you need

    If Len(rtbmain.Text) = 0 Then
    rtbmain.text = rtbmain.text & buffer & vbCrLf
    Else
    With rtbmain
    .SelStart = Len(rtbmain.Text)
    .SelLength = 1
    .SelText = .SelText & str & vbCrLf
    End With
    End If
    rtbmain.SelStart = Len(rtbmain.Text)

    That works fine for me!

  3. #3

    Thread Starter
    New Member
    Join Date
    May 2000
    Posts
    7

    Talking

    Yeah thanks for that..I figured it out the other day while going through some real old posts...now all I need to figure out is how to strip a couple of ansi codes out of the RichTextBox and color the text in between...any ideas?

    Alan

    VB6 Enterprise Edition

  4. #4
    New Member
    Join Date
    Jun 2000
    Location
    Indy, Indiana
    Posts
    2

    Arrow

    Trust me, there is no information on the web on how to do it with a rich text box. I've been working on it for over 2 years now, but finally getting some progress now. You just have to find a way to find the escape, the [, the code and the m and go from there, it's hard as heck and I have never found a resource on it.

    Good Luck

  5. #5

    Thread Starter
    New Member
    Join Date
    May 2000
    Posts
    7
    Got any tips on what functions and whatnot to look into to do that?

    Alan.

    Feel free to IM me or whatever..I am fairly new to the VB programming area.

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