SharePoint 2010 – SharePoint Alerts don't work after upgrading from SharePoint 2007 – Fix This Problem by C# Code

יום שני, אפריל 11, 2011

After upgrading to SharePoint 2010 from SharePoint 2007 or moving SharePoint 2010 to another server, Old SharePoint Alerts stop working and only new created alerts are worked. I found microsoft support arcticle http://support.microsoft.com/default.aspx?scid=kb;en-us;936759 and one blog for SharePoint 2007 with explanation: http://blogs.msdn.com/b/skelley/archive/2007/06/18/alerts.aspx I combined two those arcticles in one and build console application based on 64bit Target inside VS2010. static void Main(string args)        {            string strNewSiteCollection = string.Empty;            string strOldSiteCollection = string.Empty;            // First (and only) argument is the URL to the Site Collection            if (args.Length > 1)            {                strNewSiteCollection = args;                strOldSiteCollection = args;                try                {                    using (SPSite spsitecol = new SPSite(strNewSiteCollection))                    {                        using...