In InfoPath 2007, I have a form that has a submit button and I want to close the instance of infopath after it has been submitted. I have read the following two forums but they are not very clear on how to exactly make this happen, just detailing the code and not all the steps re where to put the code exactly.
http://www.infopathdev.com/forums/p/918/3387.aspx#3387
http://www.infopathdev.com/forums/p/2262/9360.aspx#9360
I want the instance of Infopath to be closed after the form has been submitted (via email, this part is working fine).
I have inserted the button control and right clicked for button properties, now here button properties dialog window, I can select the action submit(the only other option is rules and custom code) and then I can choose below that submit options. From there I select to allow users to submit by email, follow the GUI all they way through and it works fine.
How do add rules/code from this point on to close the infopath instance? A detailed reply or a form with a working sample would be much appreciated, thankyou.