<?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>SharePoint Integration</title><link>https://www.infopathdev.com:443/forums/46.aspx</link><description> For questions concerning issues in the integration of SharePoint and Microsoft InfoPath.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>onsubmit event handler did not work</title><link>https://www.infopathdev.com:443/forums/thread/68430.aspx</link><pubDate>Thu, 14 Jul 2011 18:45:05 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:68430</guid><dc:creator>Shyam23</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/68430.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=46&amp;PostID=68430</wfw:commentRss><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I have&amp;nbsp;published several infopath forms as content types and saved the workspace as a template. Users will create many workspaces based on my template. I need the url of the workspace when the form is opening. If I use, substring-before(substring-after(processing-instruction()[local-name(.) = &amp;quot;mso-infoPathSolution&amp;quot;], &amp;#39;href=&amp;quot;&amp;#39;), &amp;#39;&amp;quot;&amp;#39;), it gives me the url of the content type. I used the code as per this blog: &lt;a href="http://blogs.msdn.com/b/infopath/archive/2006/11/08/submitting-to-this-document-library.aspx?PageIndex=10&amp;amp;CommentPosted=true#commentmessage"&gt;http://blogs.msdn.com/b/infopath/archive/2006/11/08/submitting-to-this-document-library.aspx?PageIndex=10&amp;amp;CommentPosted=true#commentmessage&lt;/a&gt;. Now I get an error. &lt;/p&gt;
&lt;p&gt;&amp;quot;Infopath cannot submit the form The onsubmit event handler did not work&lt;/p&gt;
&lt;p&gt;The given key was not present in the dictionary.&lt;br /&gt;&amp;nbsp;&amp;nbsp; at System.ThrowHelper.ThrowKeyNotFoundException()&lt;br /&gt;&amp;nbsp;&amp;nbsp; at System.Collections.Generic.Dictionary`2.get_Item(TKey key)&lt;br /&gt;&amp;nbsp;&amp;nbsp; at Microsoft.Office.InfoPath.Internal.DataConnectionsHost.get_Item(String name)&lt;br /&gt;&amp;nbsp;&amp;nbsp; at Stakeholder_checklist_final.aspx.FormCode.FormEvents_Submit(Object sender, SubmitEventArgs e)&lt;br /&gt;&amp;nbsp;&amp;nbsp; at Microsoft.Office.InfoPath.Internal.FormEventsHost.OnSubmit(DocReturnEvent pEvent)&lt;br /&gt;&amp;nbsp;&amp;nbsp; at Microsoft.Office.Interop.InfoPath.SemiTrust._XDocumentEventSink2_SinkHelper.OnSubmitRequest(DocReturnEvent pEvent) &amp;quot;&lt;/p&gt;
&lt;p&gt;I have security as &amp;quot;full trust&amp;quot; only, but still I get this error. Can anyone guide where I am going wrong ?&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;
&lt;p&gt;Shyam&lt;br /&gt;&lt;/p&gt;</description></item></channel></rss>