I attempted to calculate a value only when the field is null and Ms doesn't like my code.
If Fld5 = Null then
The code skips all records even when they are null values.
So what is the correct coding?
Calculate only if field value is null
-
- BronzeLounger
- Posts: 1419
- Joined: 08 Jul 2016, 18:53
-
- Administrator
- Posts: 78647
- Joined: 16 Jan 2010, 00:14
- Status: Microsoft MVP
- Location: Wageningen, The Netherlands
Re: Calculate only if field value is null
Null is not really a value, but the absence of a value, so you cannot use = Null in a comparison. Use the IsNull function instead:
If IsNull(Fld5) Then
If IsNull(Fld5) Then
Best wishes,
Hans
Hans
-
- BronzeLounger
- Posts: 1419
- Joined: 08 Jul 2016, 18:53