Response.Redirect()...
-
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.Cells.Count > 0) { strGridValue = e.Row.Cells[0].Text; if (strGridValue != "ID") { e.Row.Attributes.Add("ondblclick", "javascript:alert('" + strGridValue + "')"); Session.Add("Value", strGridValue);//This Line of code will work here? Response.Redirect("Default.aspx");//This Line of code will work here? } } } This code is not working....Please help...
-
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.Cells.Count > 0) { strGridValue = e.Row.Cells[0].Text; if (strGridValue != "ID") { e.Row.Attributes.Add("ondblclick", "javascript:alert('" + strGridValue + "')"); Session.Add("Value", strGridValue);//This Line of code will work here? Response.Redirect("Default.aspx");//This Line of code will work here? } } } This code is not working....Please help...
which code is not working ... Javascript alert or Response.Redirect. I think if you redirect, why do you need to attach client attribute ?? :confused::confused:
Abhishek Sur My Latest Articles Basics on LINQ and Lambda Expressions
Create .NET Templates -
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.Cells.Count > 0) { strGridValue = e.Row.Cells[0].Text; if (strGridValue != "ID") { e.Row.Attributes.Add("ondblclick", "javascript:alert('" + strGridValue + "')"); Session.Add("Value", strGridValue);//This Line of code will work here? Response.Redirect("Default.aspx");//This Line of code will work here? } } } This code is not working....Please help...
Sr...Frank wrote:
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.Cells.Count > 0) { strGridValue = e.Row.Cells[0].Text; if (strGridValue != "ID") { e.Row.Attributes.Add("ondblclick", "javascript:alert('" + strGridValue + "')"); Session.Add("Value", strGridValue);//This Line of code will work here? Response.Redirect("Default.aspx");//This Line of code will work here? } } }
Did you tried to debug it? :~
cheers, Abhijit CodeProject MVP
-
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.Cells.Count > 0) { strGridValue = e.Row.Cells[0].Text; if (strGridValue != "ID") { e.Row.Attributes.Add("ondblclick", "javascript:alert('" + strGridValue + "')"); Session.Add("Value", strGridValue);//This Line of code will work here? Response.Redirect("Default.aspx");//This Line of code will work here? } } } This code is not working....Please help...
HI, What was error it was showing..?