I have a role called "member" and another "admin" on Asp.Net.
I did this before, this button should be visible or not, and I'm sure of it, but I canβt get the correct code (aspx.cs) to disable the button so that it can be displayed, but not on all available.
<asp:Button ID="Button4" runat="server" PostBackUrl="~/report.aspx" Text="print in report format" Width="173px" Enabled='<%# HttpContext.Current.User.IsInRole("Admin") %>' />
I want whenever the "report" button is pressed to enter the membership,
source share