0

https://developers.google.com/apps-script/reference/base/ui#showModalDialog(Object,String)

The current documentation shows that UiInstance.close() is deprecated. However, it doesn't explain how to close the dialog going forward. Is it no longer possible to close a modal from the server side?

This question is not referring to prompts but modals being opened using showModalDialog.

Rubén
  • 34,714
  • 9
  • 70
  • 166
dhan
  • 43
  • 4

1 Answers1

1

Well, it is stated in the document that you can use the google.script.host.close() for closing. I found here a SO question that use this to close a modal dialog. Just check it if it can help you.

Community
  • 1
  • 1
KENdi
  • 7,576
  • 2
  • 16
  • 31
  • 1
    `google.script.host.close()` works on the client side but it does not work on the server side. My question is related to closing the modal on the server side. – dhan Jan 29 '17 at 03:51
  • @dhan Yes so the answer is in front of you. call close from the client side as mentioned in the docs. – Sujay Phadke Jan 29 '17 at 07:42
  • @SujayPhadke You're referring to how to close the modal from the client side. My question is how to close the modal from the server side. – dhan Jan 30 '17 at 16:09
  • @SujayPhadke Where in the docs does it say that you cannot do it? I haven't seen that. – dhan Jan 30 '17 at 20:32