T
Tal
Hi all and thanks in advance for all your help.
So, I had a invalid use of Null error happening with a stack of DLookups,
which I solved with the Nz function, as exampled below:
dlookClientFirstName = Nz(DLookup("[txtClientFirstName]", "tblClients",
"[keyClient] = " & Me.Parent!keyClient), "")
dlookClientLastName = Nz(DLookup("[txtClientLastName]", "tblClients",
"[keyClient] = " & Me.Parent!keyClient), "")
However, now my whole RowSource blurb doesn't work properly because it was
dependent on the Nulls, as exampled below (don't worry that there are more
fields referenced here than I included above:
If IsNull(dlookClientLastName) = False Then
strReceiptTo = strReceiptTo & dlookClientFirstName & " " &
dlookClientLastName & ";"
End If
If IsNull(dlookCompanyOnly) = False Then
strReceiptTo = strReceiptTo & dlookCompanyOnly & ";"
End If
If IsNull(dlookSpouseFirstName) = False Then
strReceiptTo = strReceiptTo & dlookSpouseFirstName & " " &
dlookClientLastName & ";"
strReceiptTo = strReceiptTo & dlookClientFirstName & " or " &
dlookSpouseFirstName & " " & dlookClientLastName & ";"
End If
So now I am left with all kinds of empty and partial rows in my dropdown.
So, how do I rewrite the If... statement to reflect the new value of ""
instead of Null.
Again, thanks in advance.
Tal
So, I had a invalid use of Null error happening with a stack of DLookups,
which I solved with the Nz function, as exampled below:
dlookClientFirstName = Nz(DLookup("[txtClientFirstName]", "tblClients",
"[keyClient] = " & Me.Parent!keyClient), "")
dlookClientLastName = Nz(DLookup("[txtClientLastName]", "tblClients",
"[keyClient] = " & Me.Parent!keyClient), "")
However, now my whole RowSource blurb doesn't work properly because it was
dependent on the Nulls, as exampled below (don't worry that there are more
fields referenced here than I included above:
If IsNull(dlookClientLastName) = False Then
strReceiptTo = strReceiptTo & dlookClientFirstName & " " &
dlookClientLastName & ";"
End If
If IsNull(dlookCompanyOnly) = False Then
strReceiptTo = strReceiptTo & dlookCompanyOnly & ";"
End If
If IsNull(dlookSpouseFirstName) = False Then
strReceiptTo = strReceiptTo & dlookSpouseFirstName & " " &
dlookClientLastName & ";"
strReceiptTo = strReceiptTo & dlookClientFirstName & " or " &
dlookSpouseFirstName & " " & dlookClientLastName & ";"
End If
So now I am left with all kinds of empty and partial rows in my dropdown.
So, how do I rewrite the If... statement to reflect the new value of ""
instead of Null.
Again, thanks in advance.
Tal