在 Google 雲端硬碟根資料夾中建立新的文字檔案

 function createGoogleDriveTextFile() {
  var content,fileName,newFile;//Declare variable names
  
  fileName = "Test Doc " + new Date().toString().slice(0,15);//Create a new file name with date on end
  content = "This is the file Content";

  newFile = DriveApp.createFile(fileName,content);//Create a new text file in the root folder
};