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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Input masks

Status
Not open for further replies.

circles

Technical User
Feb 12, 2001
26
US
I have a form that will allow users to look up customer information by entering an ID number. All customer information is imported into the data base on a monthly basis and the customer ID numbers for some reason come with two leading zeros before the actual ID number. For example customer Jay's ID number would show up as 001234567. How can I have these two leading zeros sutomatically show in the ID field of my form so that users will only have to enter the actual 7 digit ID number?

thanks for your help.
 
Hi!

In the Before Update event procedure use this code:

txtID.Value = Format(txtID.Text,"000000000")

hth
Jeff Bridgham
 
If its only a lookup and the users are used to using a 7 digit number, set the criteria for customerID in your query to be something like:
Code:
"00" & [Forms]![frmMain]![txtCustomerID]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top