You can do this by adding an event handler RowDataBound. Add an event handler for these lines of this code:
protected void myGrid_RowDataBound(Object sender, GridViewRowEventArgs e)
{
var data = e.Row.DataItem as DataRowView;
if (data != null)
{
var lbtDownload = e.Row.FindControl("lbtDownload");
lbtDownload.Visible = (bool) data.Row["HasFileForDownload"];
}
}
In your markup, attach an event handler to the grid:
<asp:GridView OnRowDataBound="myGrid_RowDataBound" ...>
id LinkButton, , , FindControl() .
: Linux- - . , - , .