ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Date on UserForm (https://www.excelbanter.com/excel-programming/402282-date-userform.html)

TotallyConfused

Date on UserForm
 
How can I get a date stamp on a User form when it opens? I tried a textbox
with =Date() and =Now() neither works. Any help will be greatly appreciated.
Thank you.

Ron de Bruin

Date on UserForm
 
You can use this event that run when you open your userform

Private Sub UserForm_Initialize()
Me.TextBox1.Text = Format(Date, "mm-dd-yyyy")
End Sub


--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm


"TotallyConfused" wrote in message
...
How can I get a date stamp on a User form when it opens? I tried a textbox
with =Date() and =Now() neither works. Any help will be greatly appreciated.
Thank you.




All times are GMT +1. The time now is 05:31 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com