A
Alan Reinhart
(This is a re-phrasing if a previous question)
In VB Access 2003 it appears doing a direct assignment of a NULL is a No-No.
For testing purposes:
Dim x as integer
x = NULL
....produces the error message "Invalid use of NULL" (Error 94)
Likewise,
reqrs!cZXPartner = IIf(IsNull(Val(raw!cZXPartner)), 0, Val(raw!cZXPartner))
produces the same error.
If a NULL is detected in the imported raw data I want to use zero as the
value to be entered in its place in the new table.
How can this be done?
(I'm thinking I may have to resort to a full IF-ELSE block but this seems a
bit clumsy. Especially if I had a lot of incoming text fields and had to
validate EVERY one.)
=Alan R.
In VB Access 2003 it appears doing a direct assignment of a NULL is a No-No.
For testing purposes:
Dim x as integer
x = NULL
....produces the error message "Invalid use of NULL" (Error 94)
Likewise,
reqrs!cZXPartner = IIf(IsNull(Val(raw!cZXPartner)), 0, Val(raw!cZXPartner))
produces the same error.
If a NULL is detected in the imported raw data I want to use zero as the
value to be entered in its place in the new table.
How can this be done?
(I'm thinking I may have to resort to a full IF-ELSE block but this seems a
bit clumsy. Especially if I had a lot of incoming text fields and had to
validate EVERY one.)
=Alan R.