Action Block to return LOCAL DATE & TIME in CUSTOMIZABLE words

Dm114

Well-known member
This Action Block returns LOCAL DATE & TIME in CUSTOMIZABLE words (UTC times converted to your local times)

♦INPUT variables:
• Date→string date to work on (2 possible format)
- System Time format, i.e. UTC TIME, like {system_time} Magic Text or
- YYYYMMDDhhmmss format LOCAL TIME
• Length→number of characters to return for DoW & Month (-2=numerical form, -1=short alphabetical form, 0=full alphabetical form, >0=maximum fixed number of characters)
♦OUTPUT string variables, all CONVERTED TO LOCAL values:
• DoM: Day Of Month, from 1 to 31
• DoW: Day Of Week, either from 1 to 7 or alpha name
• Month, either from 1 to 12 or alpha name
• Year (4 digits)
• HhMmSs: hh:mm:ss local time
♦WORKING variable:
• CalendArr: Array with 19 indexes containing DoW & Month names TO CUSTOMIZE with your own language
Syntax:
- indexes from -1 (Monday) to -7 (Sunday) and from 1 to 12 for months
- values: "X1,X2" (separated by a comma ",") TO BE CUSTOMIZED, where:
. "X1" is YOUR shortest alphabetical acceptable form for DoW & Month
. "X2" is the full name for DoW & Month
e.g.
Index# -1→"M,Monday"
Index# -7→"Su,Sunday"
Index# 1→"Ja,January"
Index# 12→"De,December"

ℹ️ "CalendArr" array is provided with English words


This macro shows various ways "fⁿLocalDate" returns local Date & Time (texts are totally customizable)
See "fⁿLocalDate" Action Block description field for full detailed explanations
 
Top