dynamically change the sharepoint URL with infopat - InfoPath Dev
in

InfoPath Dev

dynamically change the sharepoint URL with infopat

Last post 06-20-2005 01:35 PM by Agni Jonnalagadda. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 06-17-2005 02:30 PM

    dynamically change the sharepoint URL with infopat

    Hi All,

    I'm currently designing an Infopath form that exports to Sharepoint when complete. However, the Sharepoint library that it is exported to remains unknown until certain fields in the form are filled out. Depending on certain feilds the form should submit to different Sharepoint libraries and even to different sub folders of these libraries. Does anyone know how I can do this?
    Thanks.
  • 06-18-2005 10:53 AM In reply to

    Re: dynamically change the sharepoint URL with infopat

    Hi Richard,
    Yes you can change the library name dynamically by using sharepoint DAVAdapter object. Here is code that you can use to change the form library name and submit it to sharepoint.

    //Get the Sharepoint davadapter object
    //SharepointSubmit is the your submit connection name.
    DAVAdapter oSharePoint = (DAVAdapter)thisXDocument.DataAdapters["SharepointSubmit"];

    //Here is the property of the submit that you can use
    //to change the library name dynamically
    oSharePoint.FolderURL = sSharePointFolder;

    //this line submit the data to the specified library
    oSharePoint.Submit();

    Hope this Helps!

    Agni
    InfoPathDev India
  • 06-20-2005 10:32 AM In reply to

    Re: dynamically change the sharepoint URL with infopat

    Hi Agni,

    Thanks for your help. I am now able to change the library and the folder that infopath submits to dynamically; however, I am only able to submit to sub folders that exist. I will need Infopath to be able to create new sub folders in Sharepoint since these folder names will depend on a field in the Infopath form. I am currently trying to use thehttp://<server-url>/_vti_bin/dws.asmx web service provided by Sharepoint and using the CreateFolder web method, but I am having no luck getting it to work through Infopath. Do you know how I can get this to work?
    Thanks.
  • 06-20-2005 01:35 PM In reply to

    Re: dynamically change the sharepoint URL with infopat

    Even I am not sure how it works. I will try to check it but please put the information here if you get it to work.

    Thanks!

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