Hi guys,
I need some help adding a line to my Function that will Format the numeric field as follows: "#,##0.00"
My function code:
'FUNCTION
Function IsInvalid(ctl As MSForms.Control) As Boolean
If Len(ctl.Value) = 0 Then
MsgBox "Please enter a value"
IsInvalid = True
ElseIf Not IsNumeric(ctl.Value) Then
MsgBox "Sorry, only numbers allowed"
ctl.Value = vbNullString
IsInvalid = True
End If
End Function
Private Sub txtConsumables1_Exit(ByVal Cancel As MSForms.ReturnBoolean)
Cancel = IsInvalid(txtConsumables1)
End Sub
Thank you!
Bookmarks