Five New Optimizely Certifications are Here! Validate your expertise and advance your career with our latest certification exams. Click here to find out more

List all users in code behind

Vote:
 
Hi, I was wondering if anyone knows a nice way of getting a collection of all users in code behind file? By nice I mean nicer than this: List list = new List(); UserSid us; for (int i = Int32.MinValue; i < Int32.MaxValue; i++) { us = UserSid.Load(i); if (us != null) { list.Add(us); } } I'll welcome any help. Thanks in advance.
#11385
Jun 06, 2007 15:50
Vote:
 
Maybe something like this? SidCollection sids = Sid.List(SecurityIdentityType.AnyUserSid);
#11770
Jun 08, 2007 8:37
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.