Valhalla Legends Forums Archive | General Programming | RichtTextBox Help

AuthorMessageTime
UserLoser
How can i make my RTB remove the top line(or text) when it gets filled with messages.  So when a new message comes in, it removes the top line of the RTB, this way i wont need a scroll bar on it, and wont really need a clear chat..
December 27, 2002, 12:46 PM
Grok
I'm thinking this should do it.

[code]
   Dim lPos As Long
   With rtb
       lPos = InStr(.Text, vbCrLf)
       If lPos Then
           .Text = Mid(.Text, lPos + 2)
       End If
   End With
[/code]

Hope this helps.
Grok
December 27, 2002, 1:04 PM
UserLoser
Alright thanks, ill give it a test run  ;)
December 27, 2002, 1:17 PM
Etheran
Grok, you're evil :P
December 27, 2002, 8:05 PM

Search