/ Published in: C#
                    
                                        
                            
                                Expand |
                                Embed | Plain Text
                            
                        
                        Copy this code and paste it in your HTML
string SomeUser = Page.User.Identity.Name;
if (Roles.IsUserInRole(SomeUser, "host"))
{
// if user is in role "host"
}
Comments
 Subscribe to comments
                    Subscribe to comments
                
                