|
-
Jun 4th, 2004, 03:08 AM
#1
Thread Starter
Hyperactive Member
Numeric Format
Hi, I try this code to avoid non-numeric entry to a textbox and format it by "#.#0" but it doesn't work..
Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox1.TextChanged
If Not IsNumeric(TextBox1.Text) Then
SendKeys.Send(vbBack)
End If
TextBox1.Text = Format(TextBox1.Text, "#.#0")
End Sub
What code should I write?
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
|