I have a gridview where I want to select a row and do a postback...
protected void GridView1_RowCreated(object sender, GridViewRowEventArgs e)
{
e.Row.Attributes.Add("onclick", "__doPostBack('ctl00$ContentPlaceHolder1$PharmacyGrid','Select$" + e.Row.RowIndex.ToString() + "')");
e.Row.Attributes.Add("style", "cursor:hand;");
e.Row.Attributes.Add("onmouseover", "this.originalcolor=this.style.backgroundColor;" + " this.style.backgroundColor='Yellow';");
e.Row.Attributes.Add("onmouseout", "this.style.backgroundColor=this.originalcolor;");
}
This code selects a row and does a postback....
My question is how do I get the selected row values back out so I can insert them into another table????/
protected void GridView1_RowCreated(object sender, GridViewRowEventArgs e)
{
e.Row.Attributes.Add("onclick", "__doPostBack('ctl00$ContentPlaceHolder1$PharmacyGrid','Select$" + e.Row.RowIndex.ToString() + "')");
e.Row.Attributes.Add("style", "cursor:hand;");
e.Row.Attributes.Add("onmouseover", "this.originalcolor=this.style.backgroundColor;" + " this.style.backgroundColor='Yellow';");
e.Row.Attributes.Add("onmouseout", "this.style.backgroundColor=this.originalcolor;");
}
This code selects a row and does a postback....
My question is how do I get the selected row values back out so I can insert them into another table????/