Posted on: 11/9/2011 12:23:23 PM | Views : 226

This code works to display all users registered to my site. However, I do not want all the columns.
all I want to UserName, lastactivitydate and ISonline.
How do I get rid of the rest in the gridview?
 
Also if I want to only display a user who is online in the gridview, how do I do the if statement with the ISonline column?
here is my code:
 protected void Page_Load(object sender, EventArgs e)
    {
      
     MembershipUserCollection users = Membership.GetAllUsers();
     GridView1.DataSource = users;
     GridView1.DataBind();
  
    }
thanks
...

Go to the complete details ...