I am trying to get some analytical information on how many documents are being added to a particular site or library by my company users.

Does anyone know how I can find out this kind of information? There is nothing in the site web/site collection analytic reports that gives me what I need.

  • What type of information do you need? Commented Dec 21, 2015 at 12:13
  • I find solution on site.. Click here Commented Dec 21, 2015 at 12:57

3 Answers 3


If doing custom development follow these simple steps

public static int getItemsInLastMonth(ref SPWeb web,string listName)
        SPList list = web.TryGetList(listName);
        if(list != null) {
             SPQuery query = new SPQuery();
             query.Query = "<Where>"+
                                  "<FieldRef Name='Created' />"+
                                  "<Value Type='DateTime'>+ <Today> +</Value>"+
            query.ViewFields = "<ViewFields>"+
                                   "<FieldRef Name='ID' />"+     
            SPListItemCollection collection = list.GetItems(query);

            if(collection != null){
                return collection.count;

This will give you total items created in last month. Similar you can do for document library also, and do it in client side coding.


You can generate CAML query on Document Library and fetch last month uploaded Document data. This is the easiest way to get the list of document.

--> Question : Where should you display this data?

--> Is there any requirement of generating a report of last month uploaded document?

For more reference :


    <FieldRef Name='Created' />     
        <FieldRef Name='Created' />
        <Value Type='DateTime'>"Your Date Or month"</Value>

If it's a library, you can just use a view without resorting to development. Just create a new View and make the filter into the Created equals the date of one month ago.

  • Go to the List you want to view
  • Go to the top where it says "Create View"
  • Enter in a name
  • Create a filter like it says below

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.