<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Data Connections</title><link>https://www.infopathdev.com:443/forums/44.aspx</link><description> </description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Submitting to document library in various sites</title><link>https://www.infopathdev.com:443/forums/thread/56252.aspx</link><pubDate>Mon, 28 Jun 2010 13:07:33 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:56252</guid><dc:creator>vervoorttom</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/56252.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=44&amp;PostID=56252</wfw:commentRss><description>&lt;p&gt;That doesn&amp;#39;t seem to be very difficult. :-) Thank you ! I&amp;#39;ll try this out tonight.&lt;/p&gt;</description></item><item><title>Re: Submitting to document library in various sites</title><link>https://www.infopathdev.com:443/forums/thread/56251.aspx</link><pubDate>Mon, 28 Jun 2010 13:00:24 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:56251</guid><dc:creator>mgarant</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/56251.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=44&amp;PostID=56251</wfw:commentRss><description>&lt;p&gt;Hello Vervoorttom,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Here is a code sample in C# on how to submit to a form library.&lt;/p&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;
&lt;p&gt;&lt;br /&gt;FileSubmitConnection&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; SubmitConn = (&lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;&lt;font color="#2b91af" size="2"&gt;FileSubmitConnection&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;)DataConnections[&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;Main submit&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;]; &lt;br /&gt;SubmitConn.Filename.SetStringValue(formName); &lt;br /&gt;SubmitConn.FolderUrl = &lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;http://portal/sites/rh/formulaires/Training%20Approval/&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; + formName; &lt;br /&gt;SubmitConn.Execute();&lt;font size="2"&gt;&lt;br /&gt;e.CancelableArgs.Cancel = &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;false&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;In this code you modify the Data Connection that you created to submit your form and change the url where it will be submitted. Put this code in the submit event.&lt;/p&gt;
&lt;p&gt;You will need to include this dll as well.&lt;/p&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;
&lt;p&gt;using&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; Microsoft.SharePoint;&lt;/p&gt;&lt;/font&gt;
&lt;p&gt;Hope that helps&lt;/p&gt;</description></item><item><title>Submitting to document library in various sites</title><link>https://www.infopathdev.com:443/forums/thread/56250.aspx</link><pubDate>Mon, 28 Jun 2010 12:27:25 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:56250</guid><dc:creator>vervoorttom</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/56250.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=44&amp;PostID=56250</wfw:commentRss><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I&amp;#39;ve created an administrator-approved browser form to enter project data in SharePoint. This form is used in multiple sites (all in the same site collection). All these sites are based on a template and contain one form library, so&amp;nbsp;all form libraries have the same name but a different url.&amp;nbsp;How can I configure the dataconnection so that when submitting the form, it is saved in the correct form library (the form library in the site where the user clicked &amp;#39;new&amp;#39;) ? In the new dataconnection wizard, I can only enter one document library url and it cannot be dynamic (via functions).&lt;/p&gt;
&lt;p&gt;&amp;nbsp;A solution with custom code would be ok too, as long as property promotion/demotion would work.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Regards,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Tom&lt;/p&gt;</description></item></channel></rss>