Removing Meeting Instances from SharePoint Meeting Workspaces

Removing meeting instances from a SharePoint Meeting Workspace, usually means removing some unwanted dates that you may have created in the left hand side.  Now  if like me you have created a bunch of dates by linking to the meeting workspace from Outlook and using the meeting recurrence button in Outlook – then you will have created a whole bunch of dates of the meeting workspace as similar to that shown below:-

SharePoint 2010 Meeting Workspaces

SharePoint 2010 Meeting Workspaces

Now the example screenshot above is showing meetings I have generated by linking from outlook using a single meetings (i.e. non-recurring meetings), and one of them I have unlinked, and this one is being displayed with a red-exclamation mark, which when clicked on will display a drop down box with options to change the date or delete it from list of dates.  So far so good, as the SharePoint interface is providing the mechanism to delete the date or change it.  Also a key thing to note regarding the linking of single dates to a meeting workspace is that the lists which are linked to the dates in the workspace store the information in folders which have ID values.  This becomes quite obvious when using a mobile device to access the documents associated with a meeting where the user sees folder names with 1, 2, 3, etc.

When you create a series of dates for meetings by using the recurring meetings option from Outlook, there is no way to change, alter or even remove the dates from meeting workspace after unlinking from Outlook,  after you chose the option of keeping them in the meeting series.  Essentially the interface options are lost. If you change the recurring meeting space dates from Outlook to create a different series of recurring meeting dates you will then see the red exclamation mark against the previous recurrence series where you have the option of keeping the dates, and deleting the dates.  Also note that the underlying folders associated with a meeting instance have names with dates on them, which is quite useful – why Microsoft did not use the same technique for the non-recurring meetings is rather strange.

Folder Names for Meeting Instances (Non-Recurring) Folder Names for Meeting (Recurring)

Non-Recurring Meeting Folders

Non-Recurring Meeting Folders

Recurring-MeetFolders

Recurring Meeting Folders – names are based on dates of meeting

To address the issue of dates which are now stuck (or rather orphaned) within the meeting space because you have sent out invites to individuals and are now unlinked from Outlook and you decided to keep the dates, there only way to delete them it seems is to carry out a programming exercise.  Hence the user is left to make use of Development resource to do some clean-up activity.  Microsoft have clearly recognized this short-coming and as a result have the following TechNet article to deal with removing the meeting dates:-

http://msdn.microsoft.com/en-us/library/ms465611(v=office.14).aspx

The example shown by Microsoft uses SharePoint 2010 web services, so it can be run from anywhere.  However, as the comments show – it can be rather confusing.  What it does highlight is that for a meeting workspace there is a hidden list called the ‘Meeting Series’.  You can view the lists structure using SharePoint Designer, by going to the actual meeting workspace and from Site Settings select the SharePoint Designer options.  Then from within SharePoint designer select the ‘All Files’ option for the site.  You will see under the Lists folder a list named ‘Meeting Series’.  Right click on this and select ‘Properties’, this should bring up the list of columns that exist in the list.

Accessing the Meeting Series List in Designer Columns of the Meeting Series List

Meeting Series List

Meeting Series List

Meeting Series List Columns

Meeting Series List Columns

Now – from my own testing it was only possible to view the columns of the Meeting Series after I had created a Recurring Meeting, I could not view the columns in designer where it was a non-recurring instance.  So my guess at this moment is that the actual list structure columns are only provisioned by SharePoint once a recurring meeting is created for the workspace.

To get back to the main feature of this article – my task was to get rid of load of dates from the meeting series.  To do that I used the SharePoint 2010 client model objects in a console application.  The code is shown below:-

using System; 
using System.Collections.Generic; 
using System.Linq; 
using System.Text; 
using Microsoft.SharePoint.Client; 
namespace MeetingInstancesRemoval 
{ 
 class Program 
 { 
     static void Main(string[] args) 
     { 
         ClientContext clientContext = 
              new ClientContext 
                   ("http://{mysite:port}/{subsite}/{meetingWorkspace}"); 
          Web site = clientContext.Web; 
          List list = clientContext.Web.Lists.GetByTitle("Meeting Series"); 
          CamlQuery camlQuery = new CamlQuery(); 
          camlQuery.ViewXml = "<View/>"; 
          ListItemCollection listItems = list.GetItems(camlQuery); 
          clientContext.Load(listItems); 
          clientContext.ExecuteQuery(); 
          int count = listItems.Count; 
          for (int k = 0; k < count; k++) 
          { 
            int x = (int)listItems[k]["ID"]; 
            if (x < 43) 
            { 
                Console.WriteLine( "meeting entry ID: {0}", 
                                    listItems[k]["ID"]); 
                Console.WriteLine( "Event Type is: {0}", 
                                    listItems[k]["EventType"]); 
                Console.WriteLine( "Event UID: {0}", 
                                    listItems[k]["EventUID"]); 
                Console.WriteLine( "meeting sequencie is: {0}", 
                                    listItems[k]["RecurrenceID"]); 
                Console.WriteLine( "meeting sequencie is: {0}", 
                                    listItems[k]["EventDate"]);              
                 /*  listItems[k].DeleteObject();                 
                     clientContext.ExecuteQuery();                 
                      count--; */ 
           } 
          } 
          list.Update(); 
     } 
   } 
}

Now in the code above – I have deliberately commented out the code which actually deletes the meeting instances, just in case you decide to just copy and run the code.  But the code just connects to the SharePoint server where the meeting workspace site is, and then after I have run it to identify the dates I want to get rid of (in my example above the dates were identified as the ones that had an ID less than 43), I then uncomment the line with the call to the DeleteObject().  You can identify the meetings you want to get rid of through examining the property of the EventDate.

The meeting workspaces in SharePoint 2010 are good for organising documents, and list content by the meeting dates. But the linking between Outlook in the meeting space, can become quite troublesome and if you read some other blogs you will find the various nightmares people have experienced with them.  So I think personally Microsoft have made a good decision to remove them in their current format in SharePoint 2013, although I feel that the problems most people experience could have been resolved by them so that they could be made available in SharePoint 2013.

:

Leave a Reply