<?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>Newbie Questions</title><link>https://www.infopathdev.com:443/forums/39.aspx</link><description>New to InfoPath? Search to see if your question has already been answered. If it has not, then ask it here or the appropriate topic forum.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Auto Close Infopath Application</title><link>https://www.infopathdev.com:443/forums/thread/21258.aspx</link><pubDate>Tue, 26 Jun 2007 14:43:02 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:21258</guid><dc:creator>Matt Faus</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/21258.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=21258</wfw:commentRss><description>&lt;p&gt;Hi Bill and welcome to the forums!&lt;/p&gt;&lt;p&gt;Are you sure you want to be doing all this batch processing from within InfoPath? It might be quicker for you to create a command-line application that that processes these 4000 files.&lt;/p&gt;&lt;p&gt;To add the event handler in code, double-click the button control and click Edit Form Code.&amp;nbsp; This should switch you to your CS file and create the OnClick event that you can edit.&amp;nbsp; However, I think these functions will require Full Trust of the form, and that could be difficult.&amp;nbsp; Instead, you might want&amp;nbsp;to add a Rule that closes the form after the button is clicked - this will not require Full Trust and therefore be much easier to deploy.&lt;/p&gt;</description></item><item><title>Auto Close Infopath Application</title><link>https://www.infopathdev.com:443/forums/thread/21126.aspx</link><pubDate>Thu, 21 Jun 2007 15:01:08 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:21126</guid><dc:creator>Bill </dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/21126.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=21126</wfw:commentRss><description>&lt;p&gt;Good Morning:&lt;/p&gt;&lt;p&gt;I have to open approximately 4000 XML files, export some data and then close the XML file.&amp;nbsp; I can open the form just fine and I can export the data just fine; however, I can not auto close the file once the export of the data is completed.&amp;nbsp; I have tried the following commands:&lt;/p&gt;&lt;font size="2"&gt;&lt;p&gt;thisXDocument.View.Window.Close(&lt;font color="#0000ff" size="2"&gt;True&lt;/font&gt;&lt;font size="2"&gt;) &amp;amp; thisApplication.Quit(False)&lt;/font&gt;&lt;/p&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;True&lt;/font&gt;&lt;font size="2"&gt;) &amp;amp; thisApplication.Quit(False)&lt;/font&gt;&lt;p&gt;&lt;font size="2"&gt;The only way that I can get these two commands to work sucessfully is to put them behind a button control.&amp;nbsp; So, I am looking for any help on how to either call the on click event of the button control or another way to auto close the form.&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;font size="2"&gt;Any suggestions would be greatly appreciated.&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;font size="2"&gt;Thanks!&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;strike&gt;Bill&lt;/strike&gt;&lt;/p&gt;&lt;p&gt;&lt;strike&gt;&lt;/strike&gt;&lt;/p&gt;&lt;p&gt;&lt;font size="2"&gt;&lt;p&gt;&lt;strike&gt;&lt;/strike&gt;&lt;/p&gt;&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;strike&gt;&lt;/strike&gt;&lt;/p&gt;&lt;p&gt;&lt;strike&gt;&lt;/strike&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>