TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
bob white
NA
13
99.8k
Enforce security inaspx. 3.5
Jan 5 2011 1:39 PM
// this piece of code will make the controls visible for 104 role only
if (Global.enforceSecurity)
if (!User.IsInRole("104"))
{
myDataGrid.EditButtonVisible = false;
myDataGrid.AddButtonVisible = false;
myDataGrid.DeleteButtonVisible = false;
}
Vs
// this piece of code will make the controls visible for 104 role only
if (User.IsInRole("104"))
{
myDataGrid.EditButtonVisible = true;
myDataGrid.AddButtonVisible = true;
myDataGrid.DeleteButtonVisible = true;
}
The question, is there any difference in the implementation b/e both codes above? or if you have a better code than what I have presented. please share your code and experience
thanks
Bob
Reply
Answers (
3
)
about asp.net designing page
HOW TO INSTALL SILVERLIGHT?