How to disable "save as" on close button of infopath form? It's urgent... - InfoPath Dev Sign in | Join | Help in Browser Forms InfoPath (Entire Site) InfoPath Dev InfoPath Dev is dedicated to bringing you the information and tools you need to be successful in your Microsoft Office InfoPath development projects. Home Blogs Forums Photos Downloads InfoPath Dev » InfoPath » Browser Forms » How to disable "save as" on close button of infopath form? It's urgent... How to disable "save as" on close button of infopath form? It's urgent... Last post 06-13-2018 07:36 AM by Hilary Stoupa. 17 replies. Page 1 of 2 (18 items) 1 2 Next > Sort Posts: Oldest to newest Newest to oldest Previous Next 11-15-2010 10:10 PM rahulbabar Joined on 10-08-2010 Pune Posts 62 How to disable "save as" on close button of infopath form? It's urgent... Reply Contact Hi All, I am working on browser based infopath form which has "Submit" and "Close" options. On Submit, the form is saved with the unique name. This is working fine. On Close, however if there is any change made by user in the form, a "Save As" dialog box appears. The requirement is to automatically save the form with the unique name. Basically the close button should work as Cancel button. Is there a way to disable this "Save As" dialog box without using custom button? I appreciate your suggestions. Thanks, Rahul Babar ================================================ASP.NET, C#, Sharepoint 2007/2010/2013/SP Online, Infopath 2007/2010/2013 Admin/Developer 11-15-2010 11:47 PM In reply to Rémi MATAYRON Joined on 08-28-2009 FRANCE Posts 27 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact Hi,Hi, I thik i don't understand your question. You seems to want that the close button do a submit work... Why don't you use a submit button and put the option of closing form after submit? RĂ©mi MATAYRON / MVP InfoPath Visit my blog : Infopath Blog 11-16-2010 12:55 AM In reply to rahulbabar Joined on 10-08-2010 Pune Posts 62 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact Thing is we don't want any custom button on infopath form, instead we will use standard toolbar buttons. The close button on standard toolbar asks to save the form if there is any change in the form. What close button should do is ignore the changes and just cancel the form without saving it The user should not get option to save the form, it should happen automatically only when the form is submitted. Thanks, Rahul Babar ================================================ASP.NET, C#, Sharepoint 2007/2010/2013/SP Online, Infopath 2007/2010/2013 Admin/Developer 11-16-2010 03:40 AM In reply to Patrick Halstead Joined on 08-07-2006 Posts 5,112 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact Hi Rahul, Without a lot of effort, this isnt possible. Billout RM suggests a submit approach and you *can* put the submit button in the toolbar, but it does not replace the close button. To workaround the default close functionality of the close button, you'll have to write some deep code. This is not a best practice. I recommend either putting the form in a web part or a separate app and restricting close to that. But, the easiest approach is to just tell your users what to do. Add some red guidance tex to the form telling them not to close it using the X button, or whatever... Happy trails, Patrick HalsteadProject Manager at Qdabra 11-16-2010 08:35 AM In reply to Hilary Stoupa Joined on 06-20-2008 Posts 13,297 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact Why not just disable Save and Save As? Under Form Options.... (Advanced Form Options for IP 2010). Hilary Stoupa 11-16-2010 06:47 PM In reply to rahulbabar Joined on 10-08-2010 Pune Posts 62 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact But if we disable Save and Save As, the toolbar buttons Submit & Close disappear. I am saving the form to document library on Submit. Thanks, Rahul Babar ================================================ASP.NET, C#, Sharepoint 2007/2010/2013/SP Online, Infopath 2007/2010/2013 Admin/Developer 11-17-2010 03:58 AM In reply to Patrick Halstead Joined on 08-07-2006 Posts 5,112 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact You can bind a button in your view to the Submit operation and just have it Submit to the SharePoint document library. Patrick HalsteadProject Manager at Qdabra 11-17-2010 11:00 AM In reply to Hilary Stoupa Joined on 06-20-2008 Posts 13,297 Re: How to disable "save as" on close button of infopath form? It's urgent... Options.png Mark as Not AnswerMark as Answer... Reply Contact I don't mean to be stubborn, but it appears at least in the form options that a person could choose to disable Save and Save As and Close and Submit could still show. See the attached screenshot. Are you saying these options don't work as I'd expect, and that not showing the Save command actually will also not show Close and Submit? Hilary Stoupa 11-17-2010 10:19 PM In reply to rahulbabar Joined on 10-08-2010 Pune Posts 62 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact Yes, if we uncheck Save and Save As options under Web Browser settings, Close and Submit will still be there. The issue I am facing is when user clicks on Close and if he has done some changes in the form, Save As dialog box will appear and user will be able to save the form with his preferred name. The functionality I was expecting from toolbar buttons is Submit button will submit (Save) the from to the document library in moss with autogenerated form name, the Close button will work as Cancel button (Close the form without promting for saving the form even if there is some change made by the user). As Patrick suggested, it won't be possible to change functionality of standard Close button without writing deep code. So I have used custom Close button which closes the form without Save As promt. I am still using other buttons from the standard toolbar only. I have customized close button not to look like custom button as Close (X). Thanks, Rahul Babar ================================================ASP.NET, C#, Sharepoint 2007/2010/2013/SP Online, Infopath 2007/2010/2013 Admin/Developer 04-20-2012 01:56 AM In reply to Fcollier Joined on 04-20-2012 Posts 1 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact Hello, So did you find a final solution. Tahnks. /F 08-10-2012 04:04 AM In reply to james.hartling Joined on 08-10-2012 Posts 1 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact how can I capture the onClick event of the close button in the ribbon of an infopath form running in the browser? there's no 'FormEvents_Close' method. I just want to be able to check-in the form when the user clicks close: sometimes they check-out the form then close it, without making any edits, leaving it checked out.* otherwise, on close, I could possibly do the check-in the form in a separate code artifact, EG: I could change the page to which the browser is redirected on close or submit. in that aspx page I could possibly check-in the document. I know that the url of the 'redirect page' is exposed in the query string of the url that opens the form. the query string variable is called 'source.' However, since users open forms from standard links in the library it is not clear to me how/where to re-write the value of the 'source' variable. Can I re-write this value in either of the methods InternalStartup or FormEvents_Loading? * I think hyperlinks should Only open resources Not challenge user via web forms: the user should make those decisions before clicking the link. IE, in this case, 2 links 'view' & 'edit.' 08-10-2012 08:20 AM In reply to Jimmy Joined on 07-03-2008 Posts 2,595 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact There is a way, at least in the filler, to handle an OnClose event: public void InternalStartup() { // Add the following line to the InternalStartup() method. this.Shutdown += new EventHandler(FormCode_Shutdown); } void FormCode_Shutdown(object sender, EventArgs e) { // Form close code here }not sure if this works in the browser, but it may be worth a try. Jimmy Rishe / Software Developer / Microsoft MVPQdabra Software 06-12-2018 05:03 AM In reply to Carolee Heynen Joined on 06-11-2018 Posts 3 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact I don't seem to have the ability to attach or embed a screen shot. But when I go into Form Options-->Web Browser, I have no options to check or uncheck Save, Save As, or anything else. Just a checkbox to Show InfoPath commands in Ribbon or toolbar. What am I doing wrong? I have a form with repeating table, posting the repeating values to a SharePoint list in Office 365, as well as saving a copy of the form to a library in Office 365. Filed under: Browser Forms, browser enabled forms, browser form, disable values., sharePoint online, infopath 2013 06-12-2018 07:53 AM In reply to Hilary Stoupa Joined on 06-20-2008 Posts 13,297 Re: How to disable "save as" on close button of infopath form? It's urgent... Mark as Not AnswerMark as Answer... Reply Contact You can attach a screenshot under the Options tab in a reply. If all else fails, use IE :-) You can also just attach your template and I'd be happy to take a look. Hilary Stoupa 06-12-2018 01:04 PM In reply to Carolee Heynen Joined on 06-11-2018 Posts 3 Re: How to disable "save as" on close button of infopath form? It's urgent... no options.png Mark as Not AnswerMark as Answer... Reply Contact Hilary Stoupa:You can attach a screenshot under the Options tab in a reply. If all else fails, use IE :-) You can also just attach your template and I'd be happy to take a look. Feeling pretty foolish. I didn't think to try IE. Thanks for the heads up! Here is my screenshot. Page 1 of 2 (18 items) 1 2 Next > Copyright © 2003-2019 Qdabra Software. All rights reserved.View our Terms of Use.
Hi All,
I am working on browser based infopath form which has "Submit" and "Close" options. On Submit, the form is saved with the unique name. This is working fine. On Close, however if there is any change made by user in the form, a "Save As" dialog box appears. The requirement is to automatically save the form with the unique name. Basically the close button should work as Cancel button. Is there a way to disable this "Save As" dialog box without using custom button? I appreciate your suggestions.
Thanks,
Rahul Babar
Hi,Hi,
I thik i don't understand your question. You seems to want that the close button do a submit work...
Why don't you use a submit button and put the option of closing form after submit?
Thing is we don't want any custom button on infopath form, instead we will use standard toolbar buttons. The close button on standard toolbar asks to save the form if there is any change in the form. What close button should do is ignore the changes and just cancel the form without saving it The user should not get option to save the form, it should happen automatically only when the form is submitted.
Hi Rahul,
Without a lot of effort, this isnt possible. Billout RM suggests a submit approach and you *can* put the submit button in the toolbar, but it does not replace the close button. To workaround the default close functionality of the close button, you'll have to write some deep code. This is not a best practice. I recommend either putting the form in a web part or a separate app and restricting close to that. But, the easiest approach is to just tell your users what to do. Add some red guidance tex to the form telling them not to close it using the X button, or whatever...
Happy trails,
But if we disable Save and Save As, the toolbar buttons Submit & Close disappear. I am saving the form to document library on Submit.
You can bind a button in your view to the Submit operation and just have it Submit to the SharePoint document library.
Yes, if we uncheck Save and Save As options under Web Browser settings, Close and Submit will still be there. The issue I am facing is when user clicks on Close and if he has done some changes in the form, Save As dialog box will appear and user will be able to save the form with his preferred name. The functionality I was expecting from toolbar buttons is Submit button will submit (Save) the from to the document library in moss with autogenerated form name, the Close button will work as Cancel button (Close the form without promting for saving the form even if there is some change made by the user). As Patrick suggested, it won't be possible to change functionality of standard Close button without writing deep code. So I have used custom Close button which closes the form without Save As promt. I am still using other buttons from the standard toolbar only. I have customized close button not to look like custom button as Close (X).
Hello,
So did you find a final solution.
Tahnks.
/F
There is a way, at least in the filler, to handle an OnClose event:
public void InternalStartup() { // Add the following line to the InternalStartup() method. this.Shutdown += new EventHandler(FormCode_Shutdown); }
void FormCode_Shutdown(object sender, EventArgs e) { // Form close code here }
not sure if this works in the browser, but it may be worth a try.
Hilary Stoupa:You can attach a screenshot under the Options tab in a reply. If all else fails, use IE :-) You can also just attach your template and I'd be happy to take a look.
Feeling pretty foolish. I didn't think to try IE. Thanks for the heads up! Here is my screenshot.