What should you do?
A. Add the following code segment to the Page_PreInit event handler. If Roles.GetRolesForUser("Admin") Then Page.Theme = "AdminTheme" Else Page.Theme = "DefaultTheme" End If
B. Add the following code segment to the Page_PreInit event handler. If User.IsInRole("Admin") Then Page.Theme = "AdminTheme" Else Page.Theme = "DefaultTheme" End If
C. Add the following code segment to the Page_Load event handler. If Roles.IsUserInRole("Admin") Then Page.Theme = "AdminTheme" Else Page.Theme = "DefaultTheme" End If
D. Add the following code segment to the Page_Load event handler. If User.IsInRole("Admin") Then Page.Theme = "AdminTheme" Else Page.Theme = "DefaultTheme" End If
Answer:B
What should you do?
A. Add the following code segment to the Page_PreInit event handler. If Roles.GetRolesForUser("Admin") Then Page.Theme = "AdminTheme" Else Page.Theme = "DefaultTheme" End If B. Add the following code segment to the Page_PreInit event handler. If User.IsInRole("Admin") Then Page.Theme = "AdminTheme" Else Page.Theme = "DefaultTheme" End If C. Add the following code segment to the Page_Load event handler. If Roles.IsUserInRole("Admin") Then Page.Theme = "AdminTheme" Else Page.Theme = "DefaultTheme" End If D. Add the following code segment to the Page_Load event handler. If User.IsInRole("Admin") Then Page.Theme = "AdminTheme" Else Page.Theme = "DefaultTheme" End If