title: Increment by 1 in c#
body: <p>I'm trying to count the rows in a DataList where id is 3 and put the value in a label.</p>
  
  <pre><code>for (int i = 0; i &lt; Product.Items.Count; ++i)
  {    
      if (table.Rows[i]["id"].ToString() == "3")
      {
          int x = x + 1;
          lblCounter.text = x.ToString
      }
  }
  </code></pre>