R
richard
Hi
I have a table for sub jobs and I want to increment the sub job number
starting at 1 for each main job number. However the code below just adds one
to the last sub job number, therefore my "criteria clause" in the DMAX
statement isn't working. Could someone take a look and tell me why.
Sorry about the long form names, they did seem a good idea at the time!!!!
Forms!frmnapswork!frmAssistFMSubJobNumbersSubform.Form![SubJobNumber] =
Nz(DMax("[SubJobNumber]", "tblAssistFMSubJobNumbers"),
"Forms!frmnapswork![jobnumber]=Forms!frmnapswork!frmAssistFMSubJobNumbersSubform.Form![JobNumber]") + 1
Thanks
Richard
I have a table for sub jobs and I want to increment the sub job number
starting at 1 for each main job number. However the code below just adds one
to the last sub job number, therefore my "criteria clause" in the DMAX
statement isn't working. Could someone take a look and tell me why.
Sorry about the long form names, they did seem a good idea at the time!!!!
Forms!frmnapswork!frmAssistFMSubJobNumbersSubform.Form![SubJobNumber] =
Nz(DMax("[SubJobNumber]", "tblAssistFMSubJobNumbers"),
"Forms!frmnapswork![jobnumber]=Forms!frmnapswork!frmAssistFMSubJobNumbersSubform.Form![JobNumber]") + 1
Thanks
Richard