PDA

View Full Version : Find the highest value in a column



Tezzies
12-11-2008, 03:51 AM
Dim x As String

x = DMax("[Main_Table]", "Job No")

My error message says Job No can't be found.



Any ideas

Cheers

Phil

CreganTur
12-11-2008, 06:38 AM
It's probably because your field name has a space in it (this is not a good design decision). Whenever a field name has a space in it you need to wrap it in brackets. So try this:

Dim x As String

x = DMax("[Main_Table]", "[Job No]")