1
Answer

enable the bound column property to visible if user is admin

Photo of Kriti

Kriti

15y
2.5k
1

my one of the column in a page is
<
asp:BoundColumn DataField="NotificationList" SortExpression="NotificationList" HeaderText="NotificationList"></asp:BoundColumn>
if user is admin i want to make this column visible else it should not be visible
in code behind,I have handled for SAVE button in Page_load
if
(this.UserIsAdmin())
{
this.btnSave.Visible = true;


}
else
{
this.btnSave.Visible = false;
}

but i dont know how to do it for column "NotificationList".

Answers (1)