How to view the users in web site administration tool (aspnetdb.mdf) on a page once an admin is logged in?

Hello,

I'm sort of new to ASP.net, and I was able to learn how to use the web admin tool 3.5 provides. But what I'm not sure how to do is actually view the users of that table from aspnetdb.mdf on a web form page, and I'm not sure how while still using this tool. Thanks for your help.

weihkAsked:
Who is Participating?
 
guru_samiConnect With a Mentor Commented:
Website Admin Tool uses Membership and Roles API for this purpose.
Check this: http://msdn.microsoft.com/en-us/library/ms998347.aspx#paght000022_membershipapis
Below is the sample code:
MembershipUserCollection users = Membership.GetAllUsers();
        GridView1.DataSource = users;
        GridView1.DataBind();
///Or Something like this
        foreach (MembershipUser user in users)
        {
            Response.Write(user.UserName);
        }
 foreach (MembershipUser user in users)
        {
            string username = user.UserName;
        }

Open in new window

0
 
Éric MoreauSenior .Net ConsultantCommented:
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.