2
Answers

Need to create roles in Authorization in C#

Photo of Seshadri M

Seshadri M

7y
165
1

Student Access the Exam grades

Staff can access student Exam grades
 
SuperAdmin can access ( CRUD on Exam  grades).
 
 In web config.
<authentication mode="window">
</authentication> 
<authorization>
<allow roles="Student,Staff,SuperAdmin"/>
<deny user="*"/>
</authorization>
 
// I need to created the Student, staff,SuperAdmin
 
 
in Code behind page
 
if( User.IsInRole("Student"))
{
// Access the exam grades 
 else if( User.IsInRole("Staff"))
{
// Access the student grades
}
 else if( User.IsInRole ("SuperAdmin"))
{
//Access for insert,update, delete of Exam grades  
 
 
 
 I need to created role of Student, Staff, SuperAdmin

Answers (2)

1
Photo of Joginder Banger
NA 10k 490.8k 8y
Good job keep it up..
0
Photo of ketan lohpatre
NA 35 343 8y
I am using firefox latest Version (51.0.1)
 thanks but
i have fixed it by adding custom breakpoint
just after GridView Control now it works ...
 ex:-
 
</asp:GridView>
<script type="text/javascript">
$('#grd').footable({
     breakpoints: {
     phoneP: 290,
     phoneL: 530,
     tabletP: 768,
     tabletL: 992
    }
});
</script> 
 
Thanks ...
 
 
0
Photo of Joginder Banger
NA 10k 490.8k 8y
which browser you are using. Actually this type of problem am faced many times, its seems to browser issue. please use latest browser.