Buen día.
Pueden ayudarme a cómo puedo ver mis archivos de una carperta de drive en mi app inventor 2.
Necesito listarlos y así mismo poder abrirlos para lectura desde mi app inventor2
What have you tried?
You could run a function like this on a folder from a spreadsheet
function getFileIdAndNames() {
var FileFolderID = '<HERE>'; // the ID of the folder with files
var ss = SpreadsheetApp.getActiveSpreadsheet();
var sheet = ss.getSheets()[0];
var urlCol = 1;
var urlRow = 1;
var folder = DriveApp.getFolderById(FileFolderID);
var files = folder.getFiles();
sheet.clear();
while (files.hasNext()) {
var file = files.next();
sheet.getRange(urlRow, urlCol).setValue(file.getName());
sheet.getRange(urlRow, urlCol+1).setValue(file.getId());
sheet.getRange(urlRow, urlCol+2).setValue('https://drive.google.com/uc?export=download&id='+ file.getId());
sheet.getRange(urlRow, urlCol+4).setValue(Math.round(file.getSize()/1000) + " KB");
sheet.getRange(urlRow, urlCol+5).setValue(file.getName().substring(7).slice(0, -4));
urlRow = urlRow+1;
}
sheet.sort(1, true);
sheet.sort(4, true);
sheet.insertRows(1);
var title = [["Filename","File ID","Direct Link to Download","File Size (KB)","Description"]];
var fontStyles = [ [ "bold", "bold", "bold", "bold", "bold","bold" ]];
var titleRange = sheet.getRange("A1:F1");
titleRange.setValues(title);
titleRange.setFontWeights(fontStyles);
}
then you can download this data to your app