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

How do I use a variable as a form name in a setfocus statement

Status
Not open for further replies.

chrisbee

Technical User
Oct 13, 2001
67
GB
Hi

I have several tables which hold the postcoades for different areas. Each Two Letter Prefix is a unique table.

I have a variable USEPOSTCODE which decides which table to use....but I want to perform the following:-

USEPOSTCODE="POSTCODEPO"
Forms!USEPOSTCODE!postcode.setfocus

How can I acheive this?
 
Try:
USEPOSTCODE="POSTCODEPO"
Forms(USEPOSTCODE)!postcode.setfocus


hth

Ben

----------------------------------------------
Ben O'Hara "Where are all the stupid people from...
...And how'd they get so dumb?"
rockband.gif
NoFX-The Decline
----------------------------------------------
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top