Using an IIF with a DLOOKUP?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Has anyone ever use a DLOOKUP on a report using a IIF to print an message if
the DLOOKUP comes back with a NULL value.
Would it look something like this
=IIF(Expr,Truepart,Falsepart)

if TRUE output the dlookup to the reports textbox
if FALSE print some text like “NO RECORD FOR THIS field “

=IIF(DLOOKUP(Expr,Domain,Criteria),<> NULL “print the dlookupâ€, NULL “print
no record’)
can this be done?
 
Try and use the Nz function to replace the null with a different value

=Nz(DLOOKUP(Expr,Domain,Criteria),“print no record’)
 
it works thanks!
--
thank You


Ofer said:
Try and use the Nz function to replace the null with a different value

=Nz(DLOOKUP(Expr,Domain,Criteria),“print no record’)
 
Back
Top