Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Populate Text Box with Default Date

Status
Not open for further replies.

fishey

Instructor
Oct 30, 2002
24
US
I have created a template in Word XP with bookmarks and a user form. On the user form is a text box where the user can enter a Date. Could someone tell me how to populate this text box with the current date as the default, in the format "October 8, 2003"?
 
You need to use the format command, for the On Load procedure for the form, type this

Me.TextBox1 = Format(Now(), "MMMM D, YYYY")

Where TextBox1 isa the name of your text box.

hope that helps.

muzz :)
 
Thank you, muzz, for your assistance. I am a real novice in the realm of VBA programming, having had one class and little experience. After searching the Internet for DAYS to find my answer, I thought of Tek-Tips. You answer is EXACTLY what I needed!

Sincerely,
Fish
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top