Ok does anyone have their "Smarty Pants" on today? I have a really tough one this time..
I have a Main Form Employees-it has many tabs,,one of the Tabs tracks our Labor for timesheets.So..I have a Sub Form called Time. It displays as a datasheet because we need to see what hours have been put in for the week.
Here's my problem: I need to display a field that will calculate the number of hours worked for the current week as we go along. It looks like this:
Date Job# RateCode:HrsWorked LCode TAG
1/2/02 648 55-100 8 01 REGULAR HOURS
1/3/02 648 55-100 8 01 REGULAR HOURS
1/4/02 648 55-100 8 01 REGULAR HOURS
1/7/02 648 55-100 8 01 REGULAR HOURS
1/8/02 648 55-100 8 01 REGULAR HOURS
Our work week starts on Wednesday and ends on Tuesday.To display these dates on the Employees Main Form I have 2 unbound text boxes that are filled by this code:
Private Sub Form_Open(Cancel As Integer)
Me![Beginning Date] = Date - WeekDay(Date, 4) + 1
Me![Ending Date] = Me![Beginning Date] + 6
End Sub
So.. For this week the Beginning Date=1/1/03 And the Ending Date=1/7/03. I feel like I have tried everything I know to use these dates to display a total from the Time table for the Employee for that date range.
Can anyone help me with this or is it just impossible to do???
Much thanks to anyone willing to tackle this one!!
RookieDev
I have a Main Form Employees-it has many tabs,,one of the Tabs tracks our Labor for timesheets.So..I have a Sub Form called Time. It displays as a datasheet because we need to see what hours have been put in for the week.
Here's my problem: I need to display a field that will calculate the number of hours worked for the current week as we go along. It looks like this:
Date Job# RateCode:HrsWorked LCode TAG
1/2/02 648 55-100 8 01 REGULAR HOURS
1/3/02 648 55-100 8 01 REGULAR HOURS
1/4/02 648 55-100 8 01 REGULAR HOURS
1/7/02 648 55-100 8 01 REGULAR HOURS
1/8/02 648 55-100 8 01 REGULAR HOURS
Our work week starts on Wednesday and ends on Tuesday.To display these dates on the Employees Main Form I have 2 unbound text boxes that are filled by this code:
Private Sub Form_Open(Cancel As Integer)
Me![Beginning Date] = Date - WeekDay(Date, 4) + 1
Me![Ending Date] = Me![Beginning Date] + 6
End Sub
So.. For this week the Beginning Date=1/1/03 And the Ending Date=1/7/03. I feel like I have tried everything I know to use these dates to display a total from the Time table for the Employee for that date range.
Can anyone help me with this or is it just impossible to do???
Much thanks to anyone willing to tackle this one!!
RookieDev