Tried my best at a VBScript label expression in ArcGIS Pro. The expression is 'valid', but the results are that nothing labels at all. Basically, I want my address points to only label with the [Address] field, when [Building] and [Unit] are both null. If [Building] is not null, but [Unit] is null, I want the label to display the [Address] followed on the next line by the [Building]. If [Unit] is not null, but [Building] is null, I want the label to display the [Address] followed on the next line by the [Unit]... if that makes sense.
I appreciate any help! My function is written as follows:
Function FindLabel ( [Address], [Building], [Unit] )
If (IsNull[Unit]) And (IsNull[Building]) Then
FindLabel = [Address]
ElseIf (Not IsNull[Building]) And (IsNull[Unit]) Then
FindLabel = [Address] + vbNewLine + [Building]
ElseIf (IsNull[Building]) And (Not IsNull[Unit]) Then
FindLabel = [Address] + vbNewLine + [Unit]
End If
End Function