DAY TIME CALCULATION: LAST DAY OF PREVIOUS MONTH

Discussion, questions and support.
Post Reply
Mr.Aky
Posts: 33
Joined: May 21st, ’19, 06:49

Post by Mr.Aky » Jun 9th, ’25, 07:01

Hello,
How can I send last day of previous month in a Shortcut ?

In date and time I do not find a way to send last day of previous month.
I can send first day of previous month with this formatting 01/MM/yyyy
User avatar
Marko
Posts: 1906
Joined: Mar 2nd, ’13, 21:02

Post by Marko » Jun 9th, ’25, 20:19

Code: Select all

TDate := A_YYYY A_MM "01" ; Start Date of Current Month
TDate += -1, D            ; End Date of Previous Month 
FormatTime, fileDate, %TDate%, dd.MM.yyyy
Send, %fileDate%
Mr.Aky
Posts: 33
Joined: May 21st, ’19, 06:49

Post by Mr.Aky » Jun 11th, ’25, 05:46

Thanks,
it works
Post Reply