event primary key
The UK's Number 1 for Microsoft Office Training Add this page to your favourites/bookmarksBookmark page
 
View printable version of pagePrintable version
Plus One Google
Customer: Sign in
Delegate: Sign in
Trainer: Log in

Forum home » Delegate support and help forum » Microsoft Access Training and help » Auto populate Access Filed

Auto populate Access Filed

resolvedResolved · Low Priority · Version 2003

replyReply Mon 26 Jul 2010, 11:43 Edited on Mon 26 Jul 2010, 14:19Delegate Beverley said...

Beverley has attended:
Excel Advanced course
Access Introduction course
Access Intermediate course

Auto populate Access Filed

Hello

I am setting up a training database. I have a table for schools, a table for mentors and a table for training events. In the training events table i want to be able to select the name (last & first) of the mentor and for it then to auto poulate the mentor id field ( primary key from mentor table). This is so that you dont have to know the mentor id in order to update the database. Is there anyway to do this?

Many thanks

For upcoming training course dates see: Pricing & availability

replyReply Thu 29 Jul 2010, 11:23Trainer Anthony said...

RE: Auto populate Access Filed

Hi Beverley, thanks for your query. You should be able to achieve this by changing the nature of the mentor id field to a Lookup field. You can do this in Design view. If you use the value from the name field (possibly concatenating the first and last names) and use that as your lookup value, could could then get the lookup field to search for that value in the mentor table and bring back the relevant ID number. Using a Lookup field in this way should be the quickest way to achieve what you want.

Hope this helps,

Anthony

replyReply Tue 3 Aug 2010, 13:34Delegate Beverley said...

RE: Auto populate Access Filed

Hi, thanks for that.

However as the Mentor ID field is a autonumber it cant also be a lookup field so i am not sure how to make it work.

Thanks

Beverley

replyReply Tue 10 Aug 2010, 13:23Trainer Anthony said...

RE: Auto populate Access Filed

Hi Beverly. If you can't change the Mentor field, you might need to create a custom field to put the relevant information in. I can't advise you any further without seeing the database, but if you upload it I can have a quick look or you can call our information line for assistance.

Hope this helps,

Anthony

Tue 17 Aug 2010: Automatically marked as resolved.

 

Please browse our web site to find out more about
2003 access micorosft training and other Microsoft training courses.

Access tip:

Closing form after a certain time period

To make a form close automatically after a certain time period, you need to assign the close function to a macro.

Save the macro and ope up the form in design view. open the Properties sheet.

In the TimerInterval property enter the length of time you want the form open for. This should be in milliseconds, so for instance if you want the form open for 5 seconds enter 5000, for an minute enter 60000.

You now need to attach your macro (to execute the Close action) to the OnTimer event property of the form.



View all Access hints and tips


Microsoft Certified Partner Accredited Training Provider: Institute of IT Training Institute of Leadership and Management - Certified Courses Security Seal verified by visa, mastercard securecard