Different Folders each day for attachments

I am wondering if its possible to dynamically change the folder used for the attachments based on date. In other words, we send out bills clients daily, and I would love to have a different folder in drive each day with the bills. Can you have the filepath be dynamic?

Solved Solved
0 8 792
1 ACCEPTED SOLUTION

If I have correctly understood your requirement, yes one can have dynamic folder path.

Appsheet can create a folder path on its own on a daily basis as you need.

You could name the folder path something like below. It will create a new folder such as โ€œByDate-10022020โ€ with changing date daily , under main folder โ€œClientBillsโ€ in the example below. You could suitably change the folder names etc.

CONCATENATE(โ€œClientBills/ByDate-โ€, TEXT(TODAY(), โ€œMMDDYYYYโ€))

My latest testing showed that one can name the expression without enclosing it in << >> parenthesis as mentioned in article.

View solution in original post

8 REPLIES 8

If I have correctly understood your requirement, yes one can have dynamic folder path.

Appsheet can create a folder path on its own on a daily basis as you need.

You could name the folder path something like below. It will create a new folder such as โ€œByDate-10022020โ€ with changing date daily , under main folder โ€œClientBillsโ€ in the example below. You could suitably change the folder names etc.

CONCATENATE(โ€œClientBills/ByDate-โ€, TEXT(TODAY(), โ€œMMDDYYYYโ€))

My latest testing showed that one can name the expression without enclosing it in << >> parenthesis as mentioned in article.

Thanks! Works perfectly

You are welcome . Nice to know it works. You may wish to take a look at the following point, just in case it helps.

If there is a daily folder created , there will be many daily folders in a year ( max 365 but depending on working days , there could be 250 at least) . In couple of years , there will be many folders under one single parent folder and a bit difficult to search a specific day folder.

So it may be better approach to create a folder structure something like below

CONCATENATE(โ€œClientBills/โ€, TEXT(TODAY(), โ€œMMM - YYโ€), โ€œ/โ€, "ByDate - ", TEXT(TODAY(), โ€œMMDDYYYYโ€))

The above expression will have a monthly folder in the format Mar 20 , Sep 21 etc. under main folder and followed by 28 to 31 daily folders beneath.

You could of course have the best variation in the structure that suits your requirement. Hope this helps.

That what i search thanks will try.

Can you give me the formula for saving file automaticly by actual year folderโ€™s name please

Maybe something like
CONCATENATE(โ€œYear - โ€, TEXT(TODAY(), โ€œYYYYโ€) )

Work great thanks

Uk
Silver 1
Silver 1

i've just tried this formula and worked,

For example

Create a folder in Default app folder = AppSheet Tutorial

create a Folder together with you Google Sheet data

Then, Create Bot

run data action 

create formula:

CONCATENATE("/APSHEET TUTORIAL/create file/",[Column Name 1]&"-"&[Column Name 2]&"-"&[ID]&"-"&[GENERATE PDF],".pdf")

Top Labels in this Space