Question

I am preparing the inventory for one migration project I am working on. For this I need to get all the email enabled lists. I know it is possible using powershell get Email enabled List but unfortunately I dont have access to run power shell commands in client's environment.

Is there any way through front end / client side code to check these. ? I appreciate through front end but any help is admired.

PS: I am working on WSS 3.0 and SharePoint 2013..... TIA

Était-ce utile?

La solution

I've done it in Javascript/JQuery with SPServices. Maybe you can use these ideas in another language. Call getAllEmails once per site collection with the site collection URL. I used this to see how many we used, since SharePoint online doesn't allow them. One of our sticking points of migrating to online.

function getAllEmails(url) {
        siteList = "<table><tr style='background-color: #78FF78'><td class='fmgTD'><b>Site</b></td><td class='fmgTD'><b>List</b></td><td class='fmgTD'><b>Email Address</b></td></tr>";
    getSiteLists(url, "Home");
    $().SPServices({
        operation: "GetWebCollection",
        webURL: url,
        async: false,
        completefunc: function(xData, status) {
            //      alert(xData.responseText);
            $(xData.responseXML).find("Web").each(function() {
                getSiteLists($(this).attr("Url"),$(this).attr("Title"));
                url = $(this).attr("Url");
                getSubSites(url);

            });
        }
    });
    siteList += "</table>";
    $('#emailSites').append(siteList);

}
function getSiteLists(weburl ,webtitle) {
    $().SPServices({
        operation: "GetListCollection",
        webURL: weburl,
        async: false,
        completefunc: function(xData, status) {
            var count = 0;
            $(xData.responseXML).find("List").each(function() {
                if($(this).attr("EmailAlias") && $(this).attr("EmailAlias").substr(0,13) != 'recordscenter'){
                    if(count == 0) {
                    siteList += "<tr><td class='fmgTD'>" + webtitle + "</td>";
                    } else {
                    siteList += "<tr><td class='fmgTD'>&nbsp;</td>";
                    }
                    count++;
                    siteList += "<td class='fmgTD'>" + $(this).attr("Title") + "</td><td class='fmgTD'><b>" +$(this).attr("EmailAlias") + "</b>@THEEMAILADDRESS</td></tr>";
                }
            }); 
        }               

    });
}
function getSubSites(weburl) {
    $().SPServices({
        operation: "GetWebCollection",
        webURL: weburl,
        async: false,
        completefunc: function(xData, status) {
            //      alert(xData.responseText);
            $(xData.responseXML).find("Web").each(function() {
                // now get all ists for this web
                getSiteLists($(this).attr("Url"),$(this).attr("Title") );
                getSubSites($(this).attr("Url"));

            });
        }
    });
}

Autres conseils

Email setting is not possible for all types of lists. Below are the lists where this setting is possible.

Document, picture, form library, Announcements list, Calendar list, Discussion board, Blog.

You can check this under list setting >> Communications.

Licencié sous: CC-BY-SA avec attribution
Non affilié à sharepoint.stackexchange
scroll top