I would like to get the column (Description)
from DataRowView
.I have the following code.
protected void GridView1_RowCreated(object sender, GridViewRowEventArgs e)
{
if (e.Row.DataItem != null)
{
DataRowView dataRowView = ???????????
string description = dataRowView["Description"] as string;
}
}
How to replace ??????????
with appropriate code?
Use (DataRowView)e.Row.DataItem;