# Server-side Selecting with a Select Button

You can add **GridButtonColumn** columns to a grid to handle the selection and de-selection of grid rows. The **RadGrid** [Command API](https://www.telerik.com/products/aspnet-ajax/documentation/controls/grid/control-lifecycle/command-reference-) can automatically handle the select and de-select commands: you need only add the **GridButtonColumn** objects to the **Commands** collection and set their **CommandName** property:

![Selecting a row on the server with a select button](https://www.telerik.com/products/aspnet-ajax/documentation/assets/77aa995b8a36544ae8a4c6c6fec642ea/selectbuttoncolumns.png)

```ASP.NET
	  <telerik:RadGrid RenderMode="Lightweight" ID="RadGrid1" runat="server" AllowPaging="True" PageSize="5" Skin="Silk"
	    DataSourceID="SqlDataSource1" AllowMultiRowSelection="True">
	    <MasterTableView DataSourceID="AccessDataSource1">
	      <Columns>
	        <telerik:GridButtonColumn CommandName="Select" Text="Select" UniqueName="Select">
	        </telerik:GridButtonColumn>
	        <telerik:GridButtonColumn CommandName="Deselect" Text="Deselect" UniqueName="Deselect">
	        </telerik:GridButtonColumn>
	      </Columns>
	    </MasterTableView></telerik:RadGrid>
	    <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:NorthwindConnectionString %>"
	        SelectCommand="SELECT [CustomerID], [CompanyName], [ContactName], [Country] FROM [Customers]">
	    </asp:SqlDataSource>
```

You can access the selected rows using the **SelectedItems** collection of the **RadGrid** object. In addition, you can handle the **SelectedIndexChanged** server event of the grid to detect when a row's selection changes perform additional operations if needed.

For a live example showing server-side selection, see [Server-side row selection](https://demos.telerik.com/aspnet-ajax/Grid/Examples/Programming/SelectRowWithCheckBox/DefaultCS.aspx).

## See Also

* [Selecting overview](https://www.telerik.com/products/aspnet-ajax/documentation/controls/grid/functionality/selecting/overview)
* [Server-side selection with a checkbox](https://www.telerik.com/products/aspnet-ajax/documentation/controls/grid/functionality/selecting/selecting-rows/server-side-selecting-with-a-checkbox)
