QBDevelopment
8 years agoQrew Cadet
Save & Close Window
I am trying to figure out how to create a Save & Close Window button. I have a formula - URL button that opens to a QB form in a new window that works fine using this javascript:
"javascript:void(window.open('"
& " 'URLHERE' ,' ', 'top=50,left=220,width=800,height=700,location=no,menubar=yes,toolbar=no,resizable=1,scrollbars=yes,resizable=yes,toolbar=no'))"
I also have a Save & Keep Working formula-URL button that triggers fine in the pop up window:
URLRoot() & "db/" & Dbid() & "?a=er&rid=" & [Real Estate Project ID#]& "&dfid=53&ifv=1"
However, I want to create a button that will 1) first save the form and then 2) close the window.
I can run the window.close() scriptfine on its own, but I don't know how to get the two to run sequentially.
P.S. I don't know much javascript -- I'm learning as I go. Any help is much appreciated.
"javascript:void(window.open('"
& " 'URLHERE' ,' ', 'top=50,left=220,width=800,height=700,location=no,menubar=yes,toolbar=no,resizable=1,scrollbars=yes,resizable=yes,toolbar=no'))"
I also have a Save & Keep Working formula-URL button that triggers fine in the pop up window:
URLRoot() & "db/" & Dbid() & "?a=er&rid=" & [Real Estate Project ID#]& "&dfid=53&ifv=1"
However, I want to create a button that will 1) first save the form and then 2) close the window.
I can run the window.close() scriptfine on its own, but I don't know how to get the two to run sequentially.
P.S. I don't know much javascript -- I'm learning as I go. Any help is much appreciated.