cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
lisamariew71
Nintex Newbie

Copying list items from parent to child site using web service call

I have a list called Project Dashboard in a top level site collection and each list item is a project.  I run a manual workflow from the Project Dashboard that provisions a sub-site for each list item and writes the sub-site URL back to the project list item.  This all works well.

What I want to do is be able to pull fields from an item in the project dashboard into the correct sub-site.  The sub-site URL is not fixed as it is different for each sub-site.  The sub-site URL is stored in a column called Site Link.

I have an empty Project Dashboard list in each sub-site with identical columns to the parent.  There are a few fields I want to pull across to the sub-site from the parent.

I am unable to use the Create Item In Another Site as I can't select the site when creating the workflow as I have no idea what it will  be.  If I select Enter URL, my only option is to enter a variable or an item property e.g. Site Link (html column which contains my URL to the sub-site) but this does not work.

Next I had a look at the Call Web Service action.  This did not work.  I also tried the Web Request action.

I have spent so much time on this and wondered if anybody had some advice.  Am I doing something wrong or is there some other way of achieving the same thing.

Many Thanks

Lisa

0 Kudos
Reply
3 Replies
cassymfreeman
Nintex Newbie

Re: Copying list items from parent to child site using web service call

if you use a text variable with your url it should work (instead of your hyperlink field)?  You should know what your url is to do the update anyway so just create a text variable with it in?

Reply
lisamariew71
Nintex Newbie

Re: Copying list items from parent to child site using web service call

Cassy Freeman

Are you talking about using a text variable as the url in the web service call?

0 Kudos
Reply
emha
Nintex Newbie

Re: Copying list items from parent to child site using web service call

you miss namespace prefixes for some XML nodes in the request.

try following

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:m="http://schemas.microsoft.com/sharepoint/soap/">

  <soap:Header>
  </soap:Header>
  <soap:Body>
    <m:UpdateListItems>
      <m:listName>testlist</m:listName>
      <m:updates>
        <Batch OnError="Continue">
        <Method ID="1" Cmd="New">
        <Field Name="Title">MyTitle</Field>
        <Field Name="plaintext" >text</Field>
        </Method>
        </Batch>
      </m:updates>
    </m:UpdateListItems>
  </soap:Body>
</soap:Envelope>
‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍
0 Kudos
Reply