![]() |
Number Format Controls on a User Form
I have a user form with text boxes that request dollar values. How can I
format the text box as currency when the user enters an amount? Thanks in advance for any help. |
Number Format Controls on a User Form
Private Sub TextBox1_Exit(ByVal Cancel As _
MSForms.ReturnBoolean) if isnumeric(Textbox1.Value) then Textbox1.Value = Format(cdbl(Textbox1.value),"$ #,##0.00") End If End Sub -- Regards, Tom Ogilvy "ChelseaWarren" wrote in message ... I have a user form with text boxes that request dollar values. How can I format the text box as currency when the user enters an amount? Thanks in advance for any help. |
Number Format Controls on a User Form
Tom -
Thanks a million!! "Tom Ogilvy" wrote: Private Sub TextBox1_Exit(ByVal Cancel As _ MSForms.ReturnBoolean) if isnumeric(Textbox1.Value) then Textbox1.Value = Format(cdbl(Textbox1.value),"$ #,##0.00") End If End Sub -- Regards, Tom Ogilvy "ChelseaWarren" wrote in message ... I have a user form with text boxes that request dollar values. How can I format the text box as currency when the user enters an amount? Thanks in advance for any help. |
All times are GMT +1. The time now is 05:27 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com