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

Reading Data from a table into Public Variables

Status
Not open for further replies.

JamesBBB

Technical User
Nov 2, 2005
74
GB
Hi All

I'm After some advice please,

In my database I have one table that contains config data for my database as the database reads and writes files in a specific Drive and directory specified by the user.

So I store this Data in a seperate table called [Config]. The Fields are <Drive Letter> and <Root Directory>

There is only one record in table with the two fields.

What I would like to know is, when the title form of the database opens, what would be the best way of opening this table, reading the two fields and storing them in a couple of Public strings.

I have managed to cludge this in the past, but I would really like to know an eay and efficient way of doing it.

Many many thanks in advance.

Thanks

James
 
Have a look at the DLookUp function.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Hi PH,

Apologies for the delay in responding, but have been in meetings all day.

I have tried your suggestion and it works perfectly and so simple as well.

Thankyou very much, I really appreciated the response.

James
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top