Using Min Function within DLookup Function

Joined
Jun 12, 2014
Messages
1
Reaction score
0
Does anyone know if I can use a function within a DLookup?
This is what I’m trying to do:

On a form, I have a field populate indicating the first wave for the “new” wave end time updater is auto-populated as =Min([Wave]) and the start time = current time. In order to calculate end time, I will need to know the wave duration from a table I have. The field name I used in the form to identify the current wave is “WaveCur”
The original field to retrieve the wave duration looks like this:
=IIf(DLookUp("CalcTime","Time_per_Wave","[Wave]=3")/24/60 Is Null,0,DLookUp("CalcTime","Time_per_Wave","[Wave]=3")/24/60)
But, the wave is ever changing, so I need that criteria to pull from the min wave I previously mentioned. I want to do something like this:
=IIf(DLookUp("CalcTime","UpdateTime_per_Wave","[Wave]=Min([Wave]")/24/60 Is Null,0,DLookUp("CalcTime","UpdateTime_per_Wave","[Wave]= Min([Wave]")/24/60)
Or
=IIf(DLookUp("CalcTime","UpdateTime_per_Wave","[Wave]=[UpdateWave_Times_Form]![WaveCur]")/24/60 Is Null,0,DLookUp("CalcTime","UpdateTime_per_Wave","[Wave]=[UpdateWave_Times_Form]![WaveCur]")/24/60)
But neither of those actually work….Is there a way or should I use a different function other than DLookup???
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top