ACCESS 2007 - VBA - Forms
Posted on 2011-09-09
I have an application in Access 2007. The form were related to non related tables in sql. I have created a relational db in sql and as a result I made changes to database columns and adding fk's....
I have problem with the form interface. I am not familiar with access but here is the problem I have:
The 'FORM' has a control source query in its control source, it is for example: select * from employee.
Then there are drop down boxes, which they also have their query.I select values from the dropdownbox and they wil be inerted into employee table. upon pressing enter key.
The form WAS deigned so all fields in the form had the same name of employee table columns, where information is suppose to be stored.
but now it is different. now instead of having salaryRange in employee table, I actually have only SalaryRangeID as a Foreign key in employee table.
if I select SalaryRange from salary dropdown box (which is populated using select SalaryRange from tblSalaryRange), this field (SalaryRange column) doesn't exist in employee table anymore and form generates error. (#NAME?)
how can I solve this problem.
Someone mentioned use of VIEW but I have no idea how that can be done.
Many Thanks in advance.