I have a report that is generated based on several subforms and subqueries. If there is no data for one of the queries, all the text boxes that relate to that query give me a #error.
Is there a way to change these to zero? I tried the code below, and it did not work.
Function nnz(testvalue As Variant) As Variant
'Not Numeric return zero
If Not (IsNumeric(testvalue)) Then
nnz = 0
Else
nnz = testvalue
End If
End Function
Thanks in advance.
Is there a way to change these to zero? I tried the code below, and it did not work.
Function nnz(testvalue As Variant) As Variant
'Not Numeric return zero
If Not (IsNumeric(testvalue)) Then
nnz = 0
Else
nnz = testvalue
End If
End Function
Thanks in advance.