2

I have an expressoin that works on a whole which is:

=IIF((IsNothing(Fields!Hello.Value),".",Fields!Hello.Value)

The only problem is that I have instances where it does not catch every blank. I have thought of using the "LTrinm" within the main statement. Any help would be appriciated.

Thanks,

Tito Paterson
  • 307
  • 1
  • 5
  • 15

1 Answers1

5

IsNothing() checks if a value is null however, you are searching for a blank string. Strings which are "" or " " are not evaluated as null in IsNothing() and therefore are not caught - they have a value of empty or white space.

    =IIF(LEN(Trim(Fields!Hello.Value)) = 0,".",Fields!Hello.Value)

Sidenote: This is why in the .Net CLR there is a method for both IsNullOrEmpty() and IsNullOrWhiteSpace().

ShellNinja
  • 629
  • 8
  • 25