Results 1 to 3 of 3

Thread: dificult txtbox question

  1. #1

    Thread Starter
    Member
    Join Date
    Dec 1999
    Location
    Vilnius, Lithuania
    Posts
    50

    Post

    lets say i have textbox and i want user not to type more than two simbols afterv the dot

    smth. like that

    2.11
    6322345646465456.32
    blalakbblabalaba.ms
    icantwritemorethantwosimbolsafterthed.ot

  2. #2
    Hyperactive Member Gimpster's Avatar
    Join Date
    Oct 1999
    Location
    Redmond, WA 98052
    Posts
    331

    Post

    This is just an idea that I thought up, but how about this:

    Code:
    Private Sub Text1_KeyPress()
        If KeyAscii = vbKeyDecimal Then
            Text1.MaxLength = Len(Text1.Text) + 2
        End If
    End Sub
    That might work, at least it's someplace to start.

    ------------------
    Ryan


    [This message has been edited by Gimpster (edited 01-06-2000).]

  3. #3

    Thread Starter
    Member
    Join Date
    Dec 1999
    Location
    Vilnius, Lithuania
    Posts
    50

    Post

    thanx

    -casparas

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