Return to Snippet

Revision: 11022
at January 21, 2009 07:48 by leonbda


Initial Code
string SomeUser = Page.User.Identity.Name;

if (Roles.IsUserInRole(SomeUser, "host"))
{
    // if user is in role "host"
}

Initial URL


Initial Description


Initial Title
Check if User is in Role

Initial Tags
user

Initial Language
C#