Feature Request: EnumerateFolder Web service

Jul 1, 2010 at 5:16 PM

hey there, just wanted to request a feature; EnumerateFolder.  from the Site Data web service.  and what would be really handy is if it could be run recursively.  thanks.  and LOVE the library!  I've gotten all of my co-workers into it.  :)

Coordinator
Jul 4, 2010 at 4:15 PM
Edited Aug 15, 2011 at 10:32 PM

Alex:

I've intentionally not implemented the SiteData Web Service because everything which I see in it is redundant to one of the other Web Services. In this case, you can use the GetListItems operation of the Lists Web Service.  It's a slightly different approach, but more "modern", if you will.  SiteData has been around since SharePoint 2001, I think, and the other Web Services came along afterwards.

M.

Jul 6, 2010 at 7:41 PM
But GetListItems only returns pages if they're within a doc library; any pages that are just "out there", for example default.aspx, couldn't be retrieved. from poking around the documentation, i don't think any other web service can reference those pages.
Coordinator
Jul 6, 2010 at 7:47 PM

Oh, OK, that's a different use case.  Are there any other SiteData operations you're interested in besides EnumerateFolder, since I'll be in there?

M.

Jul 6, 2010 at 7:59 PM
i don't think so; it looks like the rest, as you pointed out, seem mostly to be redundant.
Coordinator
Jul 7, 2010 at 12:56 PM

Alex:

I'll try to get this into an aplha in the next few days.

M.

Coordinator
Jul 8, 2010 at 4:14 AM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.
Coordinator
Jul 8, 2010 at 4:37 AM

Alex:

I put this into the alpha I just posted. I didn't have time to test it, so let me know if it works!

M.

Jul 8, 2010 at 4:49 PM
yup, looks like it's working.  thanks!  here's a quick and dirty example:

<script>
$(function(){
  var currentSite = $().SPServices.SPGetCurrentSite();
  var txt="
    ";
    $().SPServices({
    operation: "EnumerateFolder",
    async: false,
    strFolderUrl: currentSite,
    completefunc: function (xData, Status) {
      $(xData.responseXML).find("_sFPUrl").each(function(){
        txt += "
  • Url: "  + $("Url", this).text();
  •         txt += " IsFolder: "  + $("IsFolder",this).text();
            txt += " LastModified: " + $("LastModified",this).text() + "";
          });
        }
      });
      txt += "
    ";
      $("#Result").html("").append(txt);
    });
    </script>


    On Wed, Jul 7, 2010 at 11:37 PM, sympmarc <notifications@codeplex.com> wrote:

    From: sympmarc

    Alex:

    I put this into the alpha I just posted. I didn't have time to test it, so let me know if it works!

    M.

    Read the full discussion online.

    To add a post to this discussion, reply to this email (SPServices@discussions.codeplex.com)

    To start a new discussion for this project, email SPServices@discussions.codeplex.com

    You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

    Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com


    Jul 8, 2010 at 4:51 PM
    one other thing; i noticed on the alpha page, http://spservices.codeplex.com/releases/view/47136, that the Operation was listed as "UpdateListItems"; i'd imagine you'd want to correct that to point to "EnumerateFolder".

    a

    On Wed, Jul 7, 2010 at 11:37 PM, sympmarc <notifications@codeplex.com> wrote:

    From: sympmarc

    Alex:

    I put this into the alpha I just posted. I didn't have time to test it, so let me know if it works!

    M.

    Read the full discussion online.

    To add a post to this discussion, reply to this email (SPServices@discussions.codeplex.com)

    To start a new discussion for this project, email SPServices@discussions.codeplex.com

    You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.

    Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com


    Coordinator
    Jul 8, 2010 at 5:43 PM
    Edited Aug 15, 2011 at 10:32 PM

    a:

    Glad it works. Also, thanks for the heads up on the docs.  I just fixed that.

    Let me know if you have any issues.

    M.