Dsum but £0.00 if null

  • Thread starter Thread starter Simon
  • Start date Start date
S

Simon

I have the following code that runs on a press on a button and puts a
currently number in, however if the calcualtion is null how do i get
it to put a £0.00 in the field and not leave it blank

MonthHireTurnover = DSum("[SumOfSubTotal]", "Query8", "[SaleYear]=" &
NowYear & " And [SaleMonth]=" & NowMonth & " And [OrderType]= 3"



Thanks
 
Try putting the Nz() function around your DSum so you can specify to
make it zero when null.

Nz(DSum(...........), 0)
 
Back
Top