Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7088125
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T07:45:33+00:00 2026-05-28T07:45:33+00:00

I am trying to get a discussion with all it’s replies from the sharepoint

  • 0

I am trying to get a discussion with all it’s replies from the sharepoint web services but only seem to be able to get the root message and not any of the replies. Below is the soap XML. What am I missing?

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soap="http://schemas.microsoft.com/sharepoint/soap/">
   <soapenv:Header/>
   <soapenv:Body>
      <soap:GetListItems>
         <!--Optional:-->
         <soap:listName>Team Discussion</soap:listName>

         <soap:viewFields>
                <ViewFields>
            <FieldRef Name='Title'/>
            <FieldRef Name='ItemChildCount'/>
            <FieldRef Name='Body'/>
        </ViewFields>
         </soap:viewFields>
         <soap:queryOptions>
        <QueryOptions>
           <Folder>
        "http://Lists/Team Discussion/Bite Me"
       </Folder>
        </QueryOptions>
         </soap:queryOptions>

      </soap:GetListItems>
   </soapenv:Body>
</soapenv:Envelope>

The reply is:

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
   <soap:Body>
      <GetListItemsResponse xmlns="http://schemas.microsoft.com/sharepoint/soap/">
         <GetListItemsResult>
            <listitems xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema">
               <rs:data ItemCount="2">
                  <z:row ows_Title="Hello" ows_ItemChildCount="3;#1" ows_Body="&lt;div class=&quot;ExternalClass7B4989B3DC264716AD81B9CE55FD38FA&quot;>&lt;p>​The text of the message&lt;/p>&lt;/div>" ows_MetaInfo="3;#" ows__ModerationStatus="0" ows__Level="1" ows_ID="3" ows_UniqueId="3;#{6AF6D7DA-0D87-45EC-B002-AA0D153B6286}" ows_owshiddenversion="1" ows_FSObjType="3;#1" ows_Created="2012-01-11 12:21:26" ows_PermMask="0x7fffffffffffffff" ows_Modified="2012-01-11 12:21:26" ows_FileRef="3;#Lists/Team Discussion/Hello"/>
                  <z:row ows_Title="Bite Me" ows_ItemChildCount="1;#1" ows_Body="&lt;div class=&quot;ExternalClass76A3DB4368714038B6B75DB0D807240B&quot;>&lt;p>​Really?&lt;/p>&lt;/div>" ows_MetaInfo="1;#" ows__ModerationStatus="0" ows__Level="1" ows_ID="1" ows_UniqueId="1;#{336518DC-B806-4DFB-9483-AB8DBB6258B6}" ows_owshiddenversion="1" ows_FSObjType="1;#1" ows_Created="2012-01-09 14:16:29" ows_PermMask="0x7fffffffffffffff" ows_Modified="2012-01-09 14:16:29" ows_FileRef="1;#Lists/Team Discussion/Bite Me"/>
               </rs:data>
            </listitems>
         </GetListItemsResult>
      </GetListItemsResponse>
   </soap:Body>
</soap:Envelope>

EDIT: Each of the above posts should also have a reply.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T07:45:34+00:00Added an answer on May 28, 2026 at 7:45 am

    I eventually found the magic query. It seems sub folders are only returned when you add a query based on date, i.e. this soap request works.

    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:soap="http://schemas.microsoft.com/sharepoint/soap/">
       <soapenv:Header/>
       <soapenv:Body>
          <soap:GetListItems>
             <!--Optional:-->
             <soap:listName>969E0130-5727-4E7D-A908-B3A5BC447E24</soap:listName>
    
             <soap:viewFields>
                    <ViewFields>
                <FieldRef Name='Title'/>
                <FieldRef Name='Created'/>
                <FieldRef Name='Author'/>
                <FieldRef Name='Body'/>
            </ViewFields>
             </soap:viewFields>
    
             <soap:query>
               <Query>
            <Where>
                <Geq>
                    <FieldRef Name='Created' />
                    <Value Type='DateTime'>2010-08-20T14:00:00</Value>
                </Geq>
            </Where>
            <OrderBy><FieldRef Name='ThreadIndex' Ascending='true' /></OrderBy>
          </Query>
             </soap:query>
    
        <soap:queryOptions>
               <QueryOptions>
            <ViewAttributes Scope="RecursiveAll" IncludeRootFolder="False" />
           </QueryOptions>
             </soap:queryOptions>
          </soap:GetListItems>
       </soapenv:Body>
    </soapenv:Envelope>
    

    The essential parts are the query element with the date and the query option to specify the query is recursive.

    imho shouldn’t need the query as it should return everything by default.

    The folder option listed in the other article didn’t make any difference for me.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying get values from a GridView using the following code: foreach (GridViewRow row
I am trying get all html links within a string and replace them using
I am trying get all html links within a string and replace them using
Trying to get an ASP application deployed; it worked for a while but then
Trying to get this example working from http://www.munna.shatkotha.com/blog/post/2008/10/26/Light-box-effect-with-WPF.aspx However, I can't seem to get
Trying to get parameters from a PUT request using HttpServlet#doPut: public void doPut(HttpServletRequest request,
I am trying to sniff HTTP data through libpcap and get all the http
I am totally new to sharepoint and just trying to get something up and
I have been trying to search answer for this, but all discussions that I
I am trying get Struts 2 and Tiles to work and I am using

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.