I run a small trucking company. I have a table for orders (Deliveries). I
know that grouping on a form (like on a report) is not possible, however, is
it possible to use a tab control on a form, with 7 tabs, one for each day of
the wek, and to populate each page based on the week selected on the opening form (i.e. all Mondays jobs appear on the subform on the Monday tab, and so, on and so on...). The opening form would have either a calendar control to select the week of the year or a date picker.
My idea would be to create a select query (the same one) for each of the 7 subforms (all sub-forms would be the same), but with the selection criteria being fed by the day of the week from 1 to 7, so that each subform on each daily tab contains only the jobs for that day on the tab. Day 1 (Sunday) would be on tab Page 0, Day 2 (Monday) would be on Tab Page 1, and so on...
I know that in VBA you can select a calendar week by number, or by current week, and each weekday by number, but I'm not sure how to write the code to do this. Can anyone shed some light on this?
Wayne
know that grouping on a form (like on a report) is not possible, however, is
it possible to use a tab control on a form, with 7 tabs, one for each day of
the wek, and to populate each page based on the week selected on the opening form (i.e. all Mondays jobs appear on the subform on the Monday tab, and so, on and so on...). The opening form would have either a calendar control to select the week of the year or a date picker.
My idea would be to create a select query (the same one) for each of the 7 subforms (all sub-forms would be the same), but with the selection criteria being fed by the day of the week from 1 to 7, so that each subform on each daily tab contains only the jobs for that day on the tab. Day 1 (Sunday) would be on tab Page 0, Day 2 (Monday) would be on Tab Page 1, and so on...
I know that in VBA you can select a calendar week by number, or by current week, and each weekday by number, but I'm not sure how to write the code to do this. Can anyone shed some light on this?
Wayne