The code i posted in this thread is my only reference to a DAO database, here it is again:
Dim MyDB As DAO.Database
Dim rst As DAO.Recordset
Dim strSQL As String
Set MyDB = CurrentDb
strSQL = "SELECT * FROM tbl_daysoff WHERE EmpID = " & Me.EmpID & " ;"
Set rst = MyDB.OpenRecordset(strSQL...
Makes sense- so here is what i did:
Dim MyDB As DAO.Database
Dim rst As DAO.Recordset
Dim strSQL As String
Set MyDB = CurrentDb
strSQL = "SELECT * FROM tbl_daysoff WHERE EmpID = " & EmpID & ""
Set rst = MyDB.OpenRecordset(strSQL, dbOpenDynaset)
With rst
.Edit
![vacation] =...
no, because the primary table is the table that is storing the log in/out data so it has multiple entries for the same employee and the ID obviously changes each time. The only other thing that is unique and the same is the employee field, because obviously it only contains that employees...
Ok, I understand what you're saying. I can consolidate the employees and days off tables. With that being said, I still have the same dilemma as I am unsure when using the recordset as to how to reference the correct employee?
Thanks for the welcome!
I would prefer to have the seperate table with the exact numbers listed of days used and remaining like i have setup. The plan is to then use this for the employees. We also have carryover from previous years and some other variables that may conflict with your idea, if...
Hey!
So I have a created a timesheet database. It has a main form where an employee can sign in and out with a seperate button for each. When sign out is clicked it asks if the employee has worked a full day. If they click no it pops up a form bound to the same table as my main form...