How to create a diary template with All Days Listed?

I am creating a monthly trade diary. Like this :point_down:

I use templater Like this :point_down:

Here the days are listed from the day I run the template.

i.e if I create the file on 8th February, it starts from 8th February only.

Is there a way to automate the listing of all days of a the current month via templater?

Try something like the following. (Note: I did not have your emojis so I just used [emoji] where they should go. Substitute the appropriate emojis in their places.)

let year = await tp.system.prompt('Year','YYYY'));
let mon = await tp.system.prompt('Month','M'));
tR +='YYYY MMMM',0,`${year}/${mon}/1`,'YYYY/M/D') + ' Trade Diary [emoji]\n\n';
let curMon = mon;
let day = 0;
while (mon == curMon)
   let curDay ='dddd, Do MMMM YYYY',day,`${year}/${mon}/1`,'YYYY/M/D');

   tR += `## [emoji] ${curDay}\n`;
   tR += '### Title\n';
   tR += 'Pre Market\n';
   tR += '   - \n';
   tR += 'Market Hours\n';
   tR += '   - \n';
   tR += 'Post Market\n';
   tR += '   - \n\n';

   curMon ='M',day,`${year}/${mon}/1`,'YYYY/M/D');
1 Like

Thanks a lot :relaxed:, It Works Well. :pray:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.