MAPI scripting change SharePoint List SharingConfigUrl value RRS feed

  • Question

  • Hello,

    We have changed the URL of our SharePoint farm.
    Therefore, calendars, contacts and task lists that were connected to outlook are not synchronizing anymore.
    I am trying to use the Outlook API to change the SharePoint List STSSYNC:// url to the new URL.
    This way, our users don't have to remap the connection, by which any locally changed items since the syncronization stopped working are lost.

    I found out using the MFCMAPI tool that the STSSYNC url can be found here:
    Open MFCMapi and click on session then on Logon and display store table. Double click on Sharepoint Lists. Expand Root Container then expand Top of Personal Folders. Right click on the Calendar you have connected to outlook and select Open Associated Contents Table. Click on the sharepoint item in the top window then find the stssync address in the bottom window property 0x8020001E.

    I also installed OutlookSpy, in which I discovered that the property is called "SharingConfigUrl".

    I am using PowerShell to access the MAPI, and got this far already:

    $outlook = new-object -com outlook.application
    $namespace = $outlook.getNamespace("MAPI")
    $store = $Namespace.Stores[2]      -> "SharePoint Lists"
    $rootf = $store.GetRootFolder()
    $f = $rootf.Folders.Item(5)      -> "\\SharePoint Lists\Team - Calendar"
    $f.gettable("", 1).findrow("[from] = SharePoint").getValues()
    $table = $f.gettable("", 1)
    $table.findrow("[from] = SharePoint").getValues()

    Output of my script is:

    Following fiels are now being shown:


    By default the FROM property was not available in the list so I added it to the table.
    However, this doesn't seem to be possible for the SharingConfigUrl property, which contains my STSSYNC:// url...

    $table.columns.add("0x8020001E")   -> 0x8020001E not possible
    $table.columns.add("SharingConfigUrl")   -> SharingConfigUrl not possible

    Can anybody help me out telling me how to access this property containing the STSSYNC:// url and how I can change this?

    Even better would be if it was possible to script this on the Exchange server, so we don't have to run this script on all Outlook profiles.
    But I have never written a script to access the IMAP profiles on Exchange, so I could definitely use some help there..


    Friday, April 22, 2011 8:29 AM