|
-
Nov 27th, 2000, 07:32 PM
#1
Thread Starter
Member
This is to select a text forword
Text2.SetFocus
Text2.SelStart = 0
Text2.SelLength = Len(Text2.Text)
But this way (select a text back word):
Text1.SetFocus
Text1.SelStart = Len(Text1.Text)
Text1.SelLength = 0
it doesn't work !!
-
Nov 27th, 2000, 07:46 PM
#2
That's because you have it to select nothing.
Code:
Text2.SelLength = 0
I am confused on what you want to do though.
-
Nov 27th, 2000, 08:03 PM
#3
Thread Starter
Member
WEll when i use the code :
Text2.SetFocus
Text2.SelStart = 0
Text2.SelLength = Len(Text2.Text)
it will select the text form Left to Right and the cursor will be at the end,
what i what to do is to select the text form Right to left
so the cursor will be at the start !!: )
-
Nov 27th, 2000, 08:19 PM
#4
Something like this:
Code:
Private Sub Command1_Click()
Text2.SetFocus
Text2.SelStart = 0
Text2.SelLength = Len(Text2.Text)
Do
Text2.SelLength = Text2.SelLength - 1
DoEvents
Loop Until Text2.SelLength = 0
End Sub
-
Nov 28th, 2000, 06:35 PM
#5
Thread Starter
Member
ahhh
ahh man it doens't work 
But is it possible /
-
Nov 28th, 2000, 07:10 PM
#6
_______
<?>
Code:
'starts at beginning of text in textbox
Private Sub Text1_GotFocus()
Text1.SelStart = 0
End Sub
'starts at the end of text in textbox
Private Sub Text2_GotFocus()
Text2.SelStart = Len(Text1.Text)
End Sub
"A myth is not the succession of individual images,
but an integerated meaningful entity,
reflecting a distinct aspect of the real world."
___ Adolf Jensen
-
Nov 29th, 2000, 05:52 PM
#7
Thread Starter
Member
I don't know about you guy's but it doen's work!!
anyay is it possible ?
-
Nov 29th, 2000, 06:33 PM
#8
_______
<?>
Of course it works...all you need is two textboxes
Text1 and Text2 and then cut and copy the code.
Perhaps you should post your code.
"A myth is not the succession of individual images,
but an integerated meaningful entity,
reflecting a distinct aspect of the real world."
___ Adolf Jensen
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|