use this code as per your requirement...
protected void rdbList_SelectedIndexChanged(object sender, EventArgs e)
{
string table = "";
if (rdbDBSelection.SelectedIndex == 1)
{
table = "STUDENTLIST";
}
if(rdbDBSelection.SelectedIndex == 2)
{
table = "EMPLOYEE";
}
GetList(table);
}
GridView GridView1 = new GridView();
protected void GetList(string tableName)
{
string query = "SELEFCT * FROM " + tableName;
GridView1.DataSource = ds;
GridView1.DataBind();
}