<?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>Code</title><link>https://www.infopathdev.com:443/forums/45.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Strange save error...</title><link>https://www.infopathdev.com:443/forums/thread/38996.aspx</link><pubDate>Fri, 27 Feb 2009 03:14:59 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:38996</guid><dc:creator>geoffc</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/38996.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=38996</wfw:commentRss><description>&lt;p&gt;Hello all, one of my forms is currently saving using code but it is very simple code:&lt;/p&gt;&lt;font color="#0000ff" size="2"&gt;public&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;void&lt;/font&gt;&lt;font size="2"&gt; FormEvents_Save(&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;object&lt;/font&gt;&lt;font size="2"&gt; sender, &lt;/font&gt;&lt;font color="#008080" size="2"&gt;SaveEventArgs&lt;/font&gt;&lt;font size="2"&gt; e)&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;{&lt;/p&gt;&lt;/font&gt;&lt;font color="#008080" size="2"&gt;MessageBox&lt;/font&gt;&lt;font size="2"&gt;.Show(&lt;/font&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;Please remember to CHECK IN this document when you are finished saving it.&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;, &lt;/font&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;Check In&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;);&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;e.PerformSaveOperation();&lt;/p&gt;e.CancelableArgs.Cancel = &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;false&lt;/font&gt;&lt;font size="2"&gt;;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;}&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Basically the user wanted this prompt to come up every time the form was saved...one person managed to get this error and I am scratching my head as to why... the error is &amp;quot;Infopath cannot save the form. The OnSaveRequest function returned a value indicating that the save failed.&amp;quot; All I really did was add the messagebox. Does anyone know why this person might have received this error? Any information is appreciated. Thank you!&lt;/p&gt;
&lt;p&gt;Just some things to note..This form is published to SharePoint as a content type, it is not browser enabled, and it has full trust. One thing that I did do today was I restricted access to the main form template (made it read only). The user has contributor access to the libraries where this form will be created and stored however. Not sure if that might&amp;#39;ve played a role in this.&lt;/p&gt;&lt;/font&gt;</description></item></channel></rss>