2017-12-06 3 views
1

WebApp로 배포하려는 Google 시트에 AppsScript가 있습니다 (여러 번 해본 적이 있습니다). 공개 (누구든지 익명)로 배포했으며 링크가 다음과 같이 표시됩니다. "죄송합니다. 현재 파일을 열 수 없습니다 .주소를 확인한 후 다시 시도하십시오."웹 앱이 배포되지 않음 : 죄송합니다. 현재 파일을 열 수 없습니다.

function doGet() { 
    return HtmlService.createTemplateFromFile('Weekly.html') 
     .evaluate(); 
} 

function onOpen() { 
    var Menu = SpreadsheetApp.getUi() // Or DocumentApp or FormApp. 
     .createMenu('Survey'); 
     Menu.addItem('Run Survey', 'doSurvey') 
     .addToUi(); 
} 

function doSurvey() { 
    var html = HtmlService.createTemplateFromFile('Weekly.html') 
     .evaluate(); 
    SpreadsheetApp.getUi() // Or DocumentApp or FormApp. 
     .showModalDialog(html, ' '); 
} 

어떤 힌트 : 나는 "최신 코드에 대한 테스트 웹 응용 프로그램"을 클릭하면

이것은 또한

스크립트는 스프레드 시트 내에서 완벽하게 작동하고, 내 배포 코드는 어떻게됩니까? 감사합니다.

답변

1

이 문제는 github forum에서 해결되었습니다. 양식을 제출할 수 없습니다. 수신 중입니다. "죄송합니다. 현재 파일을 열 수 없습니다."

와 제안 된 솔루션이다 :

just remove the user part of the URL should work too, e.g. for the OP: 

https://script.google.com/macros/s/AKfycbyO4vXIPrq4smOSFpUzyQSuOxvJE9YWqlND6GfyZ3Y2lR-pPMk/exec 

we should add this to the tutorial, I suppose. also relevant for some gsuite users: 
https://stackoverflow.com/questions/26153872/cant-make-a-google-apps-script-publish-for-anonymous-users 
+0

완벽한, 감사합니다! –

관련 문제