Textbox and RTF controls .SelectionStart property differences 
Author Message
 Textbox and RTF controls .SelectionStart property differences

Hey ho,

Wassup with this? Under VB6 if you have a text box that is multiline and you
add text to it. A simple:

    Text1.SelStart = Len(Text1.Text)

would scroll the box to the bottom. Easy!

Under VB7, how come when I set the .SelectionStart property, it doesn't
work! Well, sort of, the textbox has to have focus (sorry, be 'activated')
one event loop before the .SelectionStart is done. Now, for example, if you
were writing some sort of text client (say, telnet) with a scrollable
history... or, if you were making any sort of text editor, this could be a
potential problem.

Or, is there a way around that problem?

The other problem I have noticed is that the textbox automatically selects
text when you add text to it. This is desirable in a number of cases, but
also annoying. Is there anyway to turn this 'feature' off?

I have NOT posted this under My Feedback yet... wanna see what you guys
think of this one first.

Lee Packham
(lpackham"$%thechsharps.com)



Fri, 23 May 2003 06:18:21 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Newbie Questions - 1: RTF-Control - 2: Textbox-Control

2. RTF textbox control.

3. Printing content of a TextBox or RTF while maintaining width of control

4. RTF textbox control in NT

5. Problem Programmatically Scrolling Rich TextBox Control [RTF]

6. HELP WITH RTF AND TEXTBOX CONTROL

7. RTF TextBox Control

8. 32 bit RTF control selLength and selStart properties can not be set as a long

9. Visual Basic rtf control box - document formatting properties

10. picture format in rtf code (richtext/rtf control)

11. Appending RTF strings to an RTF control

12. picture format in rtf code (richtext/rtf control)

 

 
Powered by phpBB® Forum Software