SharePoint Groups Created date
Hello,
I have a quick question about groups in SharePoint. I know there are ways to display a Sharepoint user created date. Can you do the same for a group? For example, say I created Group1. Is there anyway in SharePoint that will show the date when Group1 was
created? I have been unable to find this.
Thanks!
Chris
May 23rd, 2012 11:03am
Hi Chris,
SharePoint by default doesnt display this information in the user interface, to get the group/user information like created time, you may consider using SharePoint object model, here is the code snippet:
public static void getGroupInformation()
{
using (SPSite site = new SPSite("http://siteurl"))
{
using (SPWeb web = site.OpenWeb())
{
SPList list = web.SiteUserInfoList;
SPListItemCollection icoll = list.GetItems();
foreach (SPListItem item in icoll)
{
Console.WriteLine("item id:{0}, item name:{1}", item.ID, item.Name);
}
SPListItem itemt = list.GetItemById(26);
Console.WriteLine(itemt["Created"].ToString());
}
}
}
Thanks,
QiaoQiao Wei
TechNet Community Support
Free Windows Admin Tool Kit Click here and download it now
May 24th, 2012 6:27am
Hi Chris,
SharePoint by default doesnt display this information in the user interface, to get the group/user information like created time, you may consider using SharePoint object model, here is the code snippet:
public static void getGroupInformation()
{
using (SPSite site = new SPSite("http://siteurl"))
{
using (SPWeb web = site.OpenWeb())
{
SPList list = web.SiteUserInfoList;
SPListItemCollection icoll = list.GetItems();
foreach (SPListItem item in icoll)
{
Console.WriteLine("item id:{0}, item name:{1}", item.ID, item.Name);
}
SPListItem itemt = list.GetItemById(26);
Console.WriteLine(itemt["Created"].ToString());
}
}
}
Thanks,
QiaoQiao Wei
TechNet Community Support
May 24th, 2012 6:32am


