bdsii
10-30-2009, 10:02 AM
This is driving me nuts! :banghead:
I had this working and tried to make a change somewhere and now it will not work and I do not remember the original working code. Did I mention I am not too smart ?? :dunno
Anyway, my userform has a textbox called Amount. I want to show the text in the textbox of the userform as Currency in the format of $#,###.00 and also want the format entered into the cell in the same format.
Private Sub Amount_Exit(ByVal Cancel As MSForms.ReturnBoolean)
If Amount = vbNullString Then Exit Sub
If IsNumeric(Me.Amount.Value) Then
Me.Amount.Value = format(Me.Amount.Value, "$#,###.00")
Else
MsgBox "Number value entered"
End If
End Sub
The error I receive is " Compile Error - Wrong number of arguments or invalid property assignment "
I figure it is something obvious I have overlooked but cannot find it.
Any of you see anything ? :think:
thanks!
I had this working and tried to make a change somewhere and now it will not work and I do not remember the original working code. Did I mention I am not too smart ?? :dunno
Anyway, my userform has a textbox called Amount. I want to show the text in the textbox of the userform as Currency in the format of $#,###.00 and also want the format entered into the cell in the same format.
Private Sub Amount_Exit(ByVal Cancel As MSForms.ReturnBoolean)
If Amount = vbNullString Then Exit Sub
If IsNumeric(Me.Amount.Value) Then
Me.Amount.Value = format(Me.Amount.Value, "$#,###.00")
Else
MsgBox "Number value entered"
End If
End Sub
The error I receive is " Compile Error - Wrong number of arguments or invalid property assignment "
I figure it is something obvious I have overlooked but cannot find it.
Any of you see anything ? :think:
thanks!