Post repeating table to sharepoint list - InfoPath Dev
in

InfoPath Dev

Post repeating table to sharepoint list

Last post 12-14-2006 04:37 PM by shaun.nieves. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 12-13-2006 12:16 PM

    Post repeating table to sharepoint list

    Hi, new poster longtime reader. Please be gentle...

    I've read Matt Faus' tutorial on using the updatelistitems webservice to post to a sharepoint list and it works great however I have the same need that the previous poster required. While I would love to post to SQL, my employer wants the contents of a repeating table to post to a sharepoint list for various reasons. I have the following xml document imported as a secondary datasource.


    <?xml version="1.0" encoding="UTF-8"?>
    <Batch OnError="Continue">
    <Method ID="1" Cmd="New">
    <Field Name="METALELEMENT"></Field>
    <Field Name="METALAMNT"></Field>
    </Method>
    </Batch>



    The first row of the repeating table posts just fine however subsequent rows do not get posted. I've read there is a way to do it but requires a lot of code but have been unable to find a tutorial on how to do it. If anyone has any ideas or can point me in the right direction. I would appreciate it. Thanks!
    Shaun Nieves
    Sharepoint Manager
  • 12-14-2006 06:58 AM In reply to

    Re: Post repeating table to sharepoint list

    Hey Shaun, and welcome to the forums!

    I haven't actually implemented this, but it should be easy to do without code. Can you give the below example a try. If this doesn't work I'll be surprised be we can work around it. Thanks!

    <?xml version="1.0" encoding="UTF-8"?>
    <Batch OnError="Continue">
    <Method ID="1" Cmd="New">
    <Field Name="METALELEMENT"></Field>
    <Field Name="METALAMNT"></Field>
    </Method>
    <Method ID="2" Cmd="New">
    <Field Name="METALELEMENT">new2</Field>
    <Field Name="METALAMNT">new22</Field>
    </Method>
    <Method ID="3" Cmd="New">
    <Field Name="METALELEMENT">New3</Field>
    <Field Name="METALAMNT">New33</Field>
    </Method>
    <Method ID="4" Cmd="New">
    <Field Name="METALELEMENT">New4</Field>
    <Field Name="METALAMNT">New44</Field>
    </Method>
    </Batch>


    With this structure you should be able to setup a repeating table on your secondary dom that will mimic the SharePoint list. I hope this helps!
    Matt Faus / Microsoft InfoPath MVP
    Qdabra® Software / Streamline data gathering to turn process into knowledge
  • 12-14-2006 04:37 PM In reply to

    Re: Post repeating table to sharepoint list

    Thanks for the help Matt. I modified the XML template like you advised and it worked but I'm not sure if I did it right. The table doesn't repeat like normaly it would. When I insert the secondary datasource as a repeating table, it simply displays all of the fields.



    Is there a way to make it a functional repeating table. I remember reading somewhere that you can bind the table to the datasource onsubmit but I'm not sure where I read it )= Any ideas?

    Thanks again for your help!

    Shaun Nieves
    Sharepoint Manager
Page 1 of 1 (3 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.