user882670
user882670

Reputation:

Close sidebar with the new IFRAME mode

I'm using a sidebar in a spreadsheet. Due to the introduction of the new IFRAME mode, I'm now initialising the sidebar with:

.setSandboxMode(HtmlService.SandboxMode.IFRAME);

It is working fine, except now the following function doesn't close the sidebar after successfully running myFunction as per below:

 google.script.run
    .withSuccessHandler(google.script.host.close)
    .myFunction(myVar);

Does anyone know how to fix this?

Upvotes: 1

Views: 251

Answers (1)

Bryan P
Bryan P

Reputation: 5051

you need a () after close. google.script.host.close()

Upvotes: 1

Related Questions