fields in combobox
Distance - txtfield - column1
TotalLaps - numberfield - column2
Laprace - yes/no - column3
Racename - txtfield
Racedate - datefield
The 2nd column in combobox, is the Totallaps field.
When you select a "distance" in combobox, and this distance have ie the value 5 in the Totallaps field in column 2, then it must open XCReport5;
If you select a distance and it has ie 8 in the 2nd Totallaps column, then it must open XCReport8; etc etc etc
I have 8 different reports called report1-8 and they must be opened depending on the value in the Totallaps column 2 of the "cmb_FindXC " combox.
The value of the Totallaps column (1-8) may vary depending on the race, and it is therefore important that the XCReport1-8 is linked to this field when opening the report.
The query behind the combobox is called "Rt_XCSortQ "
(XC stands for cross-country)
i imagine it must be something to this effect in the afterupdate event of the "cmb_FindXC "
just need the finer details
Expand|Select|Wrap|Line Numbers
- If "cmb_FindXC.Column.[2] = 1 then DoCmd.OpenReport "XCReport1", acViewPreview
- elseif "cmb_FindXC.Column.[2] = 2 then DoCmd.OpenReport "XCReport2", acViewPreview
- etc etc till you get to 8th XCreport.
- elseif "cmb_FindXC.Column.[2] = 8 then DoCmd.OpenReport "XCReport8", acViewPreview