<?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>Re: Save form locally</title><link>https://www.infopathdev.com:443/forums/thread/51754.aspx</link><pubDate>Mon, 15 Feb 2010 09:28:15 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:51754</guid><dc:creator>Irianna</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/51754.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=51754</wfw:commentRss><description>&lt;p&gt;Thanks, I&amp;#39;ve managed to get it to work now with the code&lt;/p&gt;&amp;nbsp;&lt;font color="#008080" size="2"&gt;&lt;font color="#008080" size="2"&gt;XmlDocument&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; oDOM = &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;new&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#008080" size="2"&gt;&lt;font color="#008080" size="2"&gt;XmlDocument&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;();&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;Microsoft.Office.Interop.InfoPath.SemiTrust.&lt;/font&gt;&lt;font color="#008080" size="2"&gt;&lt;font color="#008080" size="2"&gt;IXMLDOMDocument&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; oWrappedDOM = thisXDocument.DOM;&lt;/p&gt;oDOM.PreserveWhitespace = &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;true&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;oDOM.LoadXml(oWrappedDOM.xml);&lt;/p&gt;
&lt;p&gt;oDOM.Save(&lt;/font&gt;&lt;font color="#800000" size="2"&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;C:\\Submit\\Form_&amp;quot;&lt;/p&gt;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;
&lt;p&gt;+ &lt;/font&gt;&lt;font color="#008080" size="2"&gt;&lt;font color="#008080" size="2"&gt;DateTime&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;.Now.ToString(&lt;/font&gt;&lt;font color="#800000" size="2"&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;yyyy.MM.dd_HH.mm.ss.ff&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;) + &lt;/font&gt;&lt;font color="#800000" size="2"&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;.xml&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;);&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;&lt;/font&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;I just need now to close the form and open a clean form up.&lt;/p&gt;&lt;/font&gt;</description></item><item><title>Re: Save form locally</title><link>https://www.infopathdev.com:443/forums/thread/51719.aspx</link><pubDate>Fri, 12 Feb 2010 16:36:25 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:51719</guid><dc:creator>Ted Fitch</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/51719.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=51719</wfw:commentRss><description>&lt;p&gt;Our qRules product has a function built in that lets you easily create a GUID: &lt;a href="http://www.qdabra.com/en/products/qRules.aspx"&gt;http://www.qdabra.com/en/products/qRules.aspx&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;We&amp;#39;ve already done the code for you.&lt;/p&gt;</description></item><item><title>Re: Save form locally</title><link>https://www.infopathdev.com:443/forums/thread/51718.aspx</link><pubDate>Fri, 12 Feb 2010 16:32:44 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:51718</guid><dc:creator>Irianna</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/51718.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=51718</wfw:commentRss><description>&lt;p&gt;Ye thats what I want, just not sure how :(&lt;/p&gt;</description></item><item><title>Re: Save form locally</title><link>https://www.infopathdev.com:443/forums/thread/51715.aspx</link><pubDate>Fri, 12 Feb 2010 16:28:55 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:51715</guid><dc:creator>Ted Fitch</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/51715.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=51715</wfw:commentRss><description>&lt;p&gt;If you need a uniuqe name you could generate a GUID using code or you could generate a unique name but concatenating some of the fields in the form with a data/time stamp, that should end up being pretty unique as one of the timestamps in InfoPath is to the milisecond&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Hope that helps!&lt;/p&gt;
&lt;p&gt;Ted&lt;/p&gt;</description></item><item><title>Save form locally</title><link>https://www.infopathdev.com:443/forums/thread/51711.aspx</link><pubDate>Fri, 12 Feb 2010 16:01:22 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:51711</guid><dc:creator>Irianna</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/51711.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=51711</wfw:commentRss><description>&lt;p&gt;Hi Folks, &lt;/p&gt;
&lt;p&gt;I&amp;#39;m in need of a littlehelp. &lt;/p&gt;
&lt;p&gt;I&amp;#39;ve got a form that submits to a SQL Database, its working perfectly fine - however, I need to get the form to work on handheld devices that are not connected to the network.&lt;/p&gt;
&lt;p&gt;What i&amp;#39;d like, is a custom button on the last view that saves the for to the C:\ as a .xml file so that when they come back onlne they can run a script i have that will open up and submit the forms.&lt;/p&gt;
&lt;p&gt;So, I&amp;#39;ve got the button and i&amp;#39;ve got some code behind it that saves the form to the local drive. The part i&amp;#39;m stuck on, is giving the saved form a unique&amp;nbsp;name.&lt;/p&gt;
&lt;p&gt;the code i&amp;#39;m using is&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;this&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;.SaveAs(&lt;/font&gt;&lt;font color="#800000" size="2"&gt;&lt;font color="#800000" size="2"&gt;&amp;quot;C:\\SavedForm.xml&amp;quot;&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;);&lt;/p&gt;&lt;/font&gt;
&lt;p&gt;Thank in advance for any help you can offer.&lt;/p&gt;
&lt;p&gt;Iri.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>