I’m currently trying to develop an app. For this app I’ve created an action that uploads a “proof of action done”, this action create a folder in My Drive with the reference of the action, then a subfolder with the date of the action and in that subfolder I have the document uploaded on the app. (CONCATENATE(“Proof_Uploads/”, [Task Key].[Reference], “/”, TEXT([Date Upload], “YYYY-MM-DD”)). I would also like to have attached/present with to the document uploaded, a pdf recording the date of upload as well as possible comments about the proof. I’ve been recommended to use an automation for this but I get the issue that the automation is creating a new folder in the default app folder. I’ve tried to change the location of the default app folder to the same folder where my master google sheet is, but then the automation just creates a new folder with the path I give it and it doesn’t add it to the folder created by the action.
In summary, I’m unable to get the uploaded documents done by the action and the record of date and comments in form of pdf to be uploaded in the same folder. Is there a way to fix it? I thought about just adding the date of upload to the name of the uploaded documents but this wouldn’t work for the comments as these can be long.
Please refer to the community discussion linked below to determine if the described scenario aligns with your current situation. I believe it provides the necessary clarification and guidance for your specific requirements. I hope it helps!
In the mean time I also looked and thought maybe the use of an Appscript could be a solution. So the solution I developed relies on a Appscript that finds the PDF document created, and copies it back in the folder where the action uploaded the proof. I’ve added a step to my bot that after the PDF is created, the Appscript is being run. It is not optimal because I double the data as it is created in the “wrong folder” and then copied in the “right one” but it seems to be working.
As I read your solution I’m not exactly sure this is something that applies exactly in my case. Maybe I didn’t explain myself properly in the issue description or I didn’t exactly understand exactly how your solution works, I’m still learning on the functioning of AppSheets.
Thank you for your feedback. I’m sharing an example of an application that successfully generates PDF files and displays them in an appsheet. Initially, I felt like you were only creating a bot that only generated PDF files. But adding another step, Putfile, to the bot makes it easier because the link to the PDF file in GDrive is already included in the table. If you’ve succeeded, it’s best to use a method that’s easy for you to understand.
Thanks again for your reponse and for puting time into this.
I think I must have not written my issue clearly. My issue is not about the display of the PDF but where it lands in my GDrive. The “action” in AppSheets uploads the files from the user in the same folder as where you main GSheet is (and for this I’ve made it create a specific folder with a specific name, eg “Action3”), whereas the “automation bot” generate the PDF and uploads it in the AppSheet default folder and it seems not possible to make the bot create the PDF in a precise already existing location. I would have liked the bot to upload the created PDF in the same folder where the action currently uploads the file given by the users (eg “Action 3”). It is possible to make the bot create a folder but not to have the upload in a specific folder. I could have put the folder “Action 3” as default but I have multiple action so it wouldn’t work.
In any case currently the AppScript seems to work just fine but I’m open to easier and better solution if you see any. Thanks again!