<?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>Closing InfoPath after Submit w/out a separate button</title><link>https://www.infopathdev.com:443/forums/thread/28691.aspx</link><pubDate>Mon, 12 May 2008 18:13:18 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:28691</guid><dc:creator>admot</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/28691.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=28691</wfw:commentRss><description>&lt;p&gt;I understand I can close the form after a submit by going to Tools\Submitting Forms...\Submit Options.&lt;/p&gt;
&lt;p&gt;However, I would like to close all of InfoPath after a submit.&amp;nbsp;I&amp;nbsp;found the following post on how to close the form via code. &amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.infopathdev.com/forums/p/6165/22781.aspx#22781"&gt;http://www.infopathdev.com/forums/p/6165/22781.aspx#22781&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I would like to do use the same submit button in the tool bar and not create a separate button. Do I just add &amp;quot;thisApplication.ActiveWindow.Close(true);&amp;quot; under an event? Which event do I use?&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;</description></item></channel></rss>