You should put it in whichever event you want the boxes to be formatted, it
doesn't set a textbox format as it does with a cell. but formats whatever is
in the textbox.
In the code I missed a vital object
For Each ctl In Me.Controls
If TypeName(ctl) = "TextBox" Then
ctl.Text = Format(ctl.Text,"#,##0")
End If
Next ctl
--
HTH
Bob Phillips
(replace xxxx in the email address with gmail if mailing direct)
"umich1967 via OfficeKB.com" <u26373@uwe wrote in message
news:66227da0c9d85@uwe...
Hi Bob:
I have entered your code, but I receive an Invalid or Unqualified
Reference
error. Should I be placing this in the form initialization (this is where
I
put it)?
Thanks for your help :)
Scott
Bob Phillips wrote:
But Halim, the OP stated that doing it for every control would be
cumbersome, which is why I took my course.
Regards
Bob
Gary,
[quoted text clipped - 36 lines]
Scott Settle
--
Message posted via http://www.officekb.com