If you don't care if more than one value equals the total then you can use the DLookUp() function. After the total is calculated you can use it to find a record in the table where the value is equal to the total in question and pull the other data. For example:
Me.txtDesiredValue = DLookUp("[B]", "MyTable", "[A] = " & Me.txtTotal)
__________________
Greg Serrano
Michigan Dept. of Environmental Quality
Air Quality Division
|