简体   繁体   English

Google表格应用脚本HTML页面隐藏关闭(X)按钮

[英]Google Sheets App Script HTML Page Hide close (X) button

I have created a html user interface for my google sheet using google app script. 我已经使用Google App脚本为我的Google工作表创建了html用户界面。 I would like to prevent the user from closing the html page and getting back to the spreadsheet. 我想防止用户关闭html页面并返回电子表格。 Is there a way to disable or hide the X in the top right hand corner of the html page. 有没有一种方法可以禁用或隐藏html页面右上角的X。 Thanks in advance 提前致谢

That is not possible. 这是不可能的。 Your UI is contained in its own IFRAME and it originates from a different domain so CORS rules apply. 您的UI包含在自己的IFRAME中,并且它来自其他域,因此适用CORS规则。 Since Google does not allow 3rd party apps to access the parent DOM there is no way for you to access the dialog element that contains the close button. 由于Google不允许第三方应用程序访问父DOM,因此您无法访问包含关闭按钮的对话框元素。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM