Saving an IP form as a file to SP list, now I need to update fields for that new record - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

Saving an IP form as a file to SP list, now I need to update fields for that new record

Last post 07-25-2014 10:34 AM by IbisDev. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 06-26-2014 12:42 PM

    Saving an IP form as a file to SP list, now I need to update fields for that new record

    This is my first post, so my apologies if I violate some standards here.

    I have an IP form that saves as a file when I submit to a SP library.  The library has three additional fields that are used to provide info and to guide workflow operations. The saving file part works perfectly.  Love it, very nice.  However.....  I cannot for the life of me figure out how to write data to the additional fields in the list record.  I have used the CAML tutorial at http://www.infopathdev.com/blogs/matt/archive/2006/02/02/Add-SharePoint-List-Items-with-InfoPath.aspx and followed it with a very similar tutorial (with a few detail changes) at http://msdn.microsoft.com/en-us/library/cc162745(office.12).aspx.  The MSDN article relies on code which isn't really an options for me.

    When I follow the directions in the first link, and work that all the way through, it works.  But I don't know why.  But it works.

    I am working on Office 365. 

    As a bit of background, the main form is a purchase requisition that includes user info, vendor info, pricing, comments - all the types of thing that you would expect to see on a PO.   I need to take the user name, the vendor name, and the total of the req and write that data to the noted additional fields.  I set up my xml file to reflect my structure, followed MS' direction on setting up data entry fields that I could access.  Set up the web service submit using updatelistitems via lists.asmx, and gave it a whirl.  And it failed.  I get an error 5567.  I have a sneaking suspicion that I am trying to write data to a non-existent record, but I have nothing to hang that on.

    I am open to ideas that help me solve this particular problem.  Any of them, including revising how I am approaching this.  I tried promoting fields to the list, but that only worked when I saved the form - but it did do what I wanted, so an equivalent to the submit functionality that permitted me to choose the name and save location would work too. 

    Thanks in advance for all assistance. 

  • 06-26-2014 11:34 PM In reply to

    Re: Saving an IP form as a file to SP list, now I need to update fields for that new record

    Hi pokihokie,

    I was able to find a very helpful thread entitled: Update Existing SharePoint List Item via Web Service & CAML from InfoPath. Please check the links which were provided there for more details. Typically, what you need to determine is the ID of the row, query those items, set CMD of the mapping file to Update instead of New, and specify the ID of the row to determine which gets updated. Hope this helps.

    Don Stephen Lambatin / Support Engineer
    Qdabra Software
  • 07-25-2014 10:34 AM In reply to

    Re: Saving an IP form as a file to SP list, now I need to update fields for that new record

     You need to publish your form to SharePoint as a Content Type. In IP Designer use Publish to SharePoint and then select Create Content Type. It will eventually ask you which field you want to add to the library when you publish the document. After the content type is created you can then add it to the Document library where you want the forms to be submitted. If you have already created the fields in the Doc Library I would delete them as the content type will add them again when you add it to the library. You can then either use the New Doc drop down to open the PO form or you can provide a link to it on a page. The data from the fields that you add when you created the content type will be added to the fields in the Doc Library when you submit the form.

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