title: Multiple if statement in VB for ArcGIS
body: <p>I have a shape-file with two columns (Thirri_2a and Thirri 2b) both are filled with positiv and negativ double values. No i want to summarize both in a new column named "Thirri". Therefore i used a if statement to check true values (not equal to 0).</p>
  
  <pre><code>Dim x As Double
  If (([Thirri_2a] = 0) And ([Thirri_2b] = 0)) Then
   x = 0
  ElseIf (([Thirri_2a] = 0) And ([Thirri_2b] &lt;&gt; 0)) Then
   x = [Thirri_2b] 
  ElseIf (([Thirri_2a] &lt;&gt; 0) And ([Thirri_2b] = 0)) Then
   x = [Thirri_2a] 
  Else (([Thirri_2a] &lt;&gt; 0) And ([Thirri_2b] &lt;&gt; 0)) 
   x = (( [Thirri_2a] + [Thirri_2b] )/2)
  End If
  </code></pre>
  
  <p>ArcGIS gives me the wonderful Errormessage:
  "Error 999999"</p>