Hi guys how are you? i made an app that shows a google execl sheet or better csv.
if I modify the sheet from google it updates.
I would like to know if I can because I can't do it when I open the app and click on a name if I want to make a change and this change must be saved on the app and also on the google drive sheet.
I attach aia file and the drive document shared with everyone
I am grateful if you can help me
thank you
hi, if I modify the sheet from Google drive it also updates in the app.I want from the app to be able to modify what I see (the drive sheet), and thus have updated the sheet on drive too.
I hope I have explained
Thank you
To update the google sheet from the app, you will need to create a google apps script web app, in order to be able to modify data. This is why i provided a link to my guide.
You do not necessarily need to change what you have already done, but you need to add much more to do what you want.
What do you not understand? If you do it, you will understand
hello, I beg your pardon you are definitely very good. I unfortunately no, I don't know how to do The script and edit so the app is Google Sheet. could you kindly give me a Aia file to download so I can modify that or you make a modification to my app please help would be important to me. thanks
HELLO, SORRY THAT MEANS
Will You Need: A Google Apps Script Web App?
WHAT SHOULD I DOWNLOAD?
THANKS AS ALWAYSI want my app to remain as it is, only clicking on the names on the screen allows you to change the wording and save.
so when I reopen the app the changes are saved
please help me i'm new i managed to do only this
help you are great
hi guys it is possible that from my project I can make the fields editable and save them either on the Google sheet or in the app. thanks you are great.
Using TextBox you can send data to Google Sheets. You can also insert a Form-Sheet in Google Sheets.
Here's an example with Firebase, but you can do it more easily.
hi antonio you are very good i'm going crazy i made this code. please know how I can make the cells editable from my app so that they are not editable and the content can be saved to google sheet in Drive.
in the forum there is the file and the link to the sheet
you can change me I don't understand how to do it
help Thank you
function doGet(e) {
return ManageSheet(e);
}
function doPost(e) {
return ManageSheet(e);
}
function ManageSheet(e) {
//READ ALL RECORDS
if ( e.parameter.func == "ReadAll") {
var ss = SpreadsheetApp.getActive();
var sh = ss.getSheets()[0];
var rg = sh.getDataRange().getValues();
var outString = '';
for(var row=0 ; row<rg.length ; ++row){
outString += rg[row].join(',') + '\n';
}
return ContentService.createTextOutput(outString).setMimeType(ContentService.MimeType.TEXT);
}
//READ SINGLE RECORD
else if ( e.parameter.func == "ReadRecord") {
var ss = SpreadsheetApp.getActive();
var sh = ss.getSheets()[0];
var rg = sh.getDataRange().getValues();
var outString = '';
outString += rg[parseInt(e.parameter.id)].join(',');
return ContentService.createTextOutput(outString).setMimeType(ContentService.MimeType.TEXT);
}
//UPDATE SINGLE RECORD
else if (e.parameter.func == "Update") {
var ss = SpreadsheetApp.getActive();
var sh = ss.getSheets()[0];
var data = [ [ e.parameter.name, e.parameter.phone ] ];
sh.getRange("B"+(parseInt(e.parameter.id)+1)+":C"+(parseInt(e.parameter.id)+1)).setValues(data);
return ContentService.createTextOutput("Success");
}
Well done, you have found youtuber HeyKal's imprecise script (poorly copied from me somewhere), which requires you to have a bound apps script project with your spreadsheet, and to ensure that your data is only in the first sheet of the spreadsheet
You need three elements setup correctly and interacting with each other:
Google Sheet
Google Apps Script Web App
Appinventor app
Have you correctly set up your google apps script web app? Linked to your spreadsheet, selecting the correct sheet on the spreadsheet? Published(Deployed) and authenticated your web app?
Do you have the web app script url in your Appinventor blocks?
Is the url you are sending to the web app formatted correctly, and contains all the correct parameters for the web app to function?
For further assistance you need to answer/confirm the above, then show your:
relevant blocks, particularly your web component calls