title: RadGrid Get Selected Row Index from Item Template Button
body: <p>I am working on a project using Telerik controls. I'm trying to figure out how to get the selected row index on an ItemTemplate button click event, like in the markup below:</p>
  
  <pre><code>&lt;telerik:RadGrid ID="RadGrid1" runat="server" AllowFilteringByColumn="True" 
      DataSourceID="cusGrid" GridLines="None" Skin="Default" AllowPaging="True" DataKeyValue="CustomerID" 
      PageSize="500" AllowMultiRowSelection="True" ShowStatusBar="true" &gt;
          &lt;MasterTableView AutoGenerateColumns="False" DataKeyNames="CustomerID" DataSourceID="cusGrid"&gt;
              &lt;RowIndicatorColumn&gt;
                  &lt;HeaderStyle Width="20px"&gt;&lt;/HeaderStyle&gt;
              &lt;/RowIndicatorColumn&gt;
              &lt;ExpandCollapseColumn&gt;
                  &lt;HeaderStyle Width="20px"&gt;&lt;/HeaderStyle&gt;
              &lt;/ExpandCollapseColumn&gt;
              &lt;Columns&gt;
                  &lt;telerik:GridTemplateColumn UniqueName="CheckBoxTemplateColumn"&gt;
                      &lt;ItemTemplate&gt;
                          &lt;asp:Button runat="server" Text="Select" OnClick="SelRecord" /&gt;
                      &lt;/ItemTemplate&gt;
                  &lt;/telerik:GridTemplateColumn&gt;
      ...
  </code></pre>
  
  <p>Normally with a <code>GridView</code> I would just do something like:</p>
  
  <pre><code>protected void SelRecord(object sender, EventArgs e)
  {
      var gRow = (GridViewRow)(sender as Control).Parent.Parent;
      var key = string.Empty;
      if (gRow != null) { key = gRow.Cells[0].Text; }
  }
  </code></pre>
  
  <p>What is the equivalent with the Telerik control?</p>