View Single Post
  #3 (permalink)  
Old February 18th, 2004, 11:06 PM
bph bph is offline
Friend of Wrox
 
Join Date: Dec 2003
Location: , , .
Posts: 102
Thanks: 2
Thanked 0 Times in 0 Posts
Default

Thanks Greg. I'll give it a shot.

[size=1]
Quote:
quote:Originally posted by SerranoG
 Put this on the form's ON OPEN event, assuming that the textbox that holds the initials is called Me.txtInitials:
Code:
   Dim strInitials as String

   strInitials = ""
   Do While strInitials = ""
      strInitials = Trim(InputBox("Please enter your initials.","User Initials"))
   Loop
   Me.txtInitials = strInitials
   Me.txtInitials.SetFocus
   The do loop is there to prevent someone from entering nothing as initials. It will keep asking until the person enters something. If you don't specify a box location, the input box will default to dead center of the screen.



Greg Serrano
Michigan Dept. of Environmental Quality, Air Quality Division
Reply With Quote