Results 1 to 9 of 9

Thread: TextBox????

  1. #1

    Thread Starter
    New Member
    Join Date
    Nov 2000
    Posts
    6

    Talking

    Friend's,

    How change the textbox for other textbox automaticly and
    make this textbox stay marked how use select all of the
    internet explorer??

    Tnk's
    ##!!##

  2. #2
    Hyperactive Member tumblingdown's Avatar
    Join Date
    Mar 2000
    Posts
    362
    pardon?


    td.
    "One logical slip and an entire scientific edifice comes tumbling down." - Robert M. Pirsig


    [email protected]

    "but if Einstein is right and God is in the details, reality requires that we sometimes get religion." - Scott Meyers.

  3. #3
    Guest

    Trying to understand

    I certainly hope I understood this right.

    Code:
    'Copy string of text1 to text2 when typing to text1
    '(do not add this to the text2 if you're using in text1!)
    Private Sub Text1_Change ()
        Text2.Text = Text1.Text
    End Sub
    
    'Selecting everything
    Private Sub Command1_Click ()
        Text1.SelStart = 1
        Text1.SelLength = Len(Text1.Text)
    End Sub
    This was just a guess...Internet Explorer? What it has to do with this?

    Anyway, I hope this helps and was the thing,

  4. #4
    Hyperactive Member Asaf_99's Avatar
    Join Date
    Jul 2000
    Location
    Israel
    Posts
    335

    Re: Trying to understand

    Originally posted by MerryVIP
    I certainly hope I understood this right.

    Code:
    'Copy string of text1 to text2 when typing to text1
    '(do not add this to the text2 if you're using in text1!)
    Private Sub Text1_Change ()
        Text2.Text = Text1.Text
    End Sub
    
    'Selecting everything
    Private Sub Command1_Click ()
        Text1.SelStart = 1
        Text1.SelLength = Len(Text1.Text)
    End Sub
    This was just a guess...Internet Explorer? What it has to do with this?

    Anyway, I hope this helps and was the thing,
    Still didn't understan!
    I think the prblem is that the SelStart is 1 instead of 0.
    Asaf Sagi

    ICQ: 61917199
    E-Mail: [email protected]

  5. #5

    Thread Starter
    New Member
    Join Date
    Nov 2000
    Posts
    6
    Friend's,

    I'm beginning in VB and my english is terrible!!!

    I'm want change of textbox for other textbox automaticly,
    select the lenght of the textbox next. simulation one TAB
    when the lenght = MaxLength.


    ex.:

    If Len(N(0).Text) = N(0).MaxLength Then
    N(1).SetFocus
    End If

    Please, help me to make better is code!!!

    tnk's
    ##!!##

  6. #6
    Guest

    Got it...I hope

    Oh, you're meaning that if textbox text length is, for example, three, then it goes to the next textbox?

    For following example, you need to add Text1, Text2 and Command1. Set MaxLength of textboxes to 5 or anything you want. Empty textboxes text (text?.text = ""). Then paste following code:

    Code:
    Private Sub Text1_KeyUp(KeyCode As Integer, Shift As Integer)
        If Len(Text1.Text) >= Text1.MaxLength Then Text2.SetFocus
    End Sub
    
    Private Sub Text2_KeyDown(KeyCode As Integer, Shift As Integer)
        If KeyCode = 8 And Len(Text2.Text) < 1 Then
            Text1.SelStart = Len(Text1.Text)
            Text1.SetFocus
        End If
    End Sub
    
    Private Sub Text2_KeyUp(KeyCode As Integer, Shift As Integer)
        If Len(Text2.Text) >= Text2.MaxLength Then Command1.SetFocus
    End Sub
    
    Private Sub Command1_Click ()
        End
    End Sub
    
    Private Sub Command1_KeyDown(KeyCode As Integer, Shift As Integer)
        If KeyCode = 8 Then
            Text2.SelStart = Len(Text2.Text)
            Text2.SetFocus
        End If
    End Sub

    Where are you from? I'm a Finn. There is maybe someone who can speak same language you do.

    Don't worry about your English skills yet, I was like you about two-three years ago

    Try reading a book, an English one, it's very good way to learn the language.

    Hope all this helps,

  7. #7

    Thread Starter
    New Member
    Join Date
    Nov 2000
    Posts
    6

    Wink

    Tnk's Merry,

    I'm from Brazil, and don't like study english, but I'm going try...


    Merry again I'm not got make textbox stay selected..

    Most something about this case!!!

    Tnk's

    Obs.: How make appear the icons in message??
    ##!!##

  8. #8
    Frenzied Member Jop's Avatar
    Join Date
    Mar 2000
    Location
    Amsterdam, the Netherlands
    Posts
    1,986
    Hi... MerryVIP, kedaman is finnish too...

    and rlamrf, to make the smileys and others, look here:
    http://209.207.250.147/index.php?action=showsmilies
    Jop - validweb.nl

    Alcohol doesn't solve any problems, but then again, neither does milk.

  9. #9

    Thread Starter
    New Member
    Join Date
    Nov 2000
    Posts
    6
    Tnk's, and my case!!!
    ##!!##

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