Save csv to Google Drive

This

image

should set to:

"Anyone"

This information is provided in one of the links i gave you earlier:

there is not anyone

Cualqueir usario == Any user == Anyone

Did you complete the permissions review, or stop at the position in the last image you showed ?

I can't go any further

I have noticed that when I create app Script
with in the content

function myFunction() {

}

If you allow me to obtain the
Web Application
URL

but if I start with
function doPost(e) {

var data = Utilities.base64Decode(e.parameters.data);

var blob = Utilities.newBlob(data, e.parameters.mimetype, e.parameters.filename);

DriveApp.createFile(blob);

return ContentService.createTextOutput("Your File Successfully Uploaded");

}

It doesn't allow me to get the
Web Application
URL

This means that I must first obtain the Web Application
URL

then fill code.gs
including the Web Application
URL and content
then
execute

but anyway all the forms always refer me to authorization

If there was a video example I would appreciate it.

Google Apps Script: Review Permissions:

image

Click on Review Permissions

Select the google account you want to use and click on it

image

Click on "Advanced" link

image

Click on the "Go to (unsafe)" link

Click on "Allow"

1 Like

perfect

I get this notice
seems to be from time
image

Looks like you are not getting a file to convert to a base64String. Check your blocks.

image

when starting it is created
ai2logo.png
and that is what he keeps and if he is already saving it

You appear to be showing four images in the root of your google drive. Are these being up loaded by the app ? So everything is working ?

yes everything solved
thank you

I try to save a csv and I can't, according to the description it indicates that it saves different types of formats

The other thing is where I position the csv to be able to send it to the driv

You should be able to save a csv file.

Here:

image

you are trying to set the filename to the contents of a list. That is not correct, is it ?

If you would also like to change the file name

For example, the content of the CSV file would be
[["a","b","c"],["1","2","4"]]

and the file name would be
Name.csv

You have no blocks to save the content to a file

from the screen where I view the content of the csv I need to upload to google drive

I managed to change the name and upload the file
When I open the content I only display the content of the extension string, not the content of the csv

I think I'm doing something wrong

Do you have any example?

Example aia project:

Simple_UAFTGD_CSV.aia (26.6 KB)

This project uses this script:

function doPost(e) {
    var data = Utilities.base64Decode(e.parameters.data);
    var blob = Utilities.newBlob(data, e.parameters.mimetype, e.parameters.filename);
    var fileID = DriveApp.createFile(blob).getId();
    return ContentService.createTextOutput(fileID);
    }

which returns the ID of the file.

1 Like

perfect
thank you TIMAI2

image

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.