When a new employee is hired, the main DB has a button (new employee) which
opens a small form asking for the name, team assignment and employee ID.
This infor is written to Table1, and the employee needs to be written to
Table2 also.
So far, i have not been able to get this to work.
Can anyone offer some assistance, please?
Thank You.
Use the After Insert event procedure to execute an Append query statement
that writes the new record. This kind of thing:
Private sub Form_AfterInsert()
dim strSql As String
strSql = "INSERT INTO Table 2 ( EmployeeID ) SELECT " & _
Me.EmployeeID & " AS EmpID;"
db.Execute strSql, dbFailOnError
End Sub
--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.
"HMJessen" <HMJe...@discussions.microsoft.com> wrote in message
news:BF2E2DAB-0831-438B...@microsoft.com...
I think I will have to play with it a bit as it isn't working right out of
the box, but hey, that is how we all learn.
Thank you for the help.