alaska@pozo

VBA: If Then with OR

Discussion created by alaska@pozo on Sep 7, 2013
Latest reply on Sep 9, 2013 by rfairhur24
Hello,

I'm tryng to populate a field with this VBA code but it doesn't work. I really appreciate any help you can provide.

Dim codigo as string

If [CAMPO]="Captura" OR [CAMPO]="Replanteo" OR [CAMPO]="GPS" Then
       codigo = "1"
    ElseIf [CAMPO]="Plano" OR [CAMPO]="Ortofoto" Then
        codigo = "2"
    ElseIf [CAMPO]="Catastro" OR [CAMPO]="Ajuste parcelario" Then
        codigo = "3"
    Else codigo = [CAMPO]

EndIf



__esri_field_calculator_splitter__
codigo

Outcomes