brgdotnet
asked on
How to hyperlink e.Rows.Cells[1].Text before it is displayed in the GridView control.
I am loading a GridView from a data source. Before the GridView is displayed, I need to hyperlink the
row cell item. How would I do that below for e.Rows.Cells[1].Text below? As you can see I am able to italicize the text, but I don't
know how to instead hyperlink it? Can an Asp.net expert help me out?
protected void CustomersGridView_RowDataB ound(Objec t sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow )
{
// Display the company name in italics.
e.Row.Cells[1].Text = "<i>" + e.Row.Cells[1].Text + "</i>";
}
}
row cell item. How would I do that below for e.Rows.Cells[1].Text below? As you can see I am able to italicize the text, but I don't
know how to instead hyperlink it? Can an Asp.net expert help me out?
protected void CustomersGridView_RowDataB
{
if (e.Row.RowType == DataControlRowType.DataRow
{
// Display the company name in italics.
e.Row.Cells[1].Text = "<i>" + e.Row.Cells[1].Text + "</i>";
}
}
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
No. It needs to be done using C#. Nothing in the Markup.
What we suggested IS part of the C# backend part ...
Hi,
Have you tried my suggestion ?
Regards,
Pawan
Have you tried my suggestion ?
Regards,
Pawan
Open in new window