Results 1 to 7 of 7

Thread: limiting the decimal point to 1

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Apr 2005
    Posts
    12

    limiting the decimal point to 1

    I find that most code to limit the decimal point to one is written similar to this.

    If KeyAscii = 46 And InStr(Text1, ".") > 0 Then
    KeyAscii = 0
    Exit Sub
    or
    Case 8, 48 To 57, 46 And InStr(TextBox, ".") = 0

    The downside is that there must be a integer before the decimal point for it to function. Is there no way to limit the decimal point to one AND have the decimal point be the first digit entered? An example would be something less than 1 like .625

    I have tried all that I know so far to no avail. Any ideas?

    Thanks
    Last edited by Davek1; Aug 25th, 2006 at 09:41 AM.

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