export-google-form
export-google-form copied to clipboard
:arrow_down_small: A small Google Apps Script file to export a form into a JSON file.
The file generated will now be uploaded to Google Drive. Upon completion, a link will be shared to download the file. 
I get this error This is the form https://docs.google.com/forms/d/e/1FAIpQLSfzFxg9xl_MUtDjWtnOi_AUI_zn9dHuxOzORqnQ3lFfYCx0Fw/viewform?usp=sf_link
the syntax changed as per #9
When the form is too large, the JSON gets too big for the Logger and the output gets truncated. I've looked into saving a JSON from App Script to Google...
Thank you!
The error is in this code snippet. ``` // Downcast items to access type-specific properties var itemTypeConstructorName = snakeCaseToCamelCase("AS_" + item.getType().toString() + "_ITEM"); var typedItem = item[itemTypeConstructorName](); ```
Why is running the appscript giving this error?
Line 57 is: ``` var typedItem = item[itemTypeConstructorName](); ``` And `itemTypeConstructorName` for this specific `item` is `"asFileUploadItem"`. I do have a file field on this form. Am I missing something?
Simply add `data.title = typedItem.getTitle();` -> like so: ``` switch (item.getType()) { case FormApp.ItemType.LIST: case FormApp.ItemType.CHECKBOX: case FormApp.ItemType.MULTIPLE_CHOICE: data.title = typedItem.getTitle(); data.choices = typedItem.getChoices().map(function(choice) { return choice.getValue(); }); break; ```
Error msg : No item with the given ID could be found, or you do not have permission to access it. Try my own form and other form are still...