I have 3 roles on my page, so I want to get access to link with two roles.
I try something like this
@if(User.IsInRole("Admin,User"))
{
//my code
}
Or this
@if (User.IsInRole("Admin") && User.IsInRole("User"))
{
//my code
}
No one work's, the only one who I managed to works is this:
@if (User.IsInRole("Admin")
But this last one it's only for one Role, How can I do that I want?