SharePoint and Insight related code