Hi,
I process an excel file either on a friday, monday or tuesday. Is there anyway to send the nearest staurdays date to the spreadsheet?.
Thx,
John
Dates
Moderators: Dorian (MJT support), JRL
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Code to get nearest Saturday's date:
Code: Select all
GetDate>thedate
DayOfWeek>dow
If>dow<4
//If today is Tuesday or less, get Sat gone
Sub>thedate,dow
else
//if today is Wed or more, get Sat coming
Let>dow=7-dow
Add>thedate,dow
endif
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?