B
Bill
I have two forms - Employee Data and Employee Assignments.
Both forms have some similar fields such as EmployeeID,
FirstName, LastName, HireDate, Department. On the Employee
Assignments form, I have additional fields such as
StartDate, EndDate, AssignmentCode, AssignmentType.
Normally, the Employee Data form is completed sevral days
before the Employee Assignment form is first used.
However, sometimes we may hire a new employee and from the
Data form, we want to click a command button to take us to
the Assignments form for this employee.
My code is as follows:
Dim strDocName As String
Dim strWhere As String
strDocName = "Employee Assignments"
DoCmd.DoMenuItem as FormBar, ac RecordsMenu, ac
SaveRecord, ac MenuVer 70
DoCmd.OpenForm strDocName, acNormal, strWhere
Whenever I press the command button, I go to the first
record in the Assignments form rather than the currect
record from the Data form. Any ideas what I'm missing?
Both forms have some similar fields such as EmployeeID,
FirstName, LastName, HireDate, Department. On the Employee
Assignments form, I have additional fields such as
StartDate, EndDate, AssignmentCode, AssignmentType.
Normally, the Employee Data form is completed sevral days
before the Employee Assignment form is first used.
However, sometimes we may hire a new employee and from the
Data form, we want to click a command button to take us to
the Assignments form for this employee.
My code is as follows:
Dim strDocName As String
Dim strWhere As String
strDocName = "Employee Assignments"
DoCmd.DoMenuItem as FormBar, ac RecordsMenu, ac
SaveRecord, ac MenuVer 70
DoCmd.OpenForm strDocName, acNormal, strWhere
Whenever I press the command button, I go to the first
record in the Assignments form rather than the currect
record from the Data form. Any ideas what I'm missing?