Is it possible to add the suffixes onto the end of a date? I am referring to the "th", "rd", "nd" and "st" after the number. I have tried to use substitutes but haven't got very good results.
Here is what I have now, which does not work.
[MeasureDate]
Measure=Time
Format="The current time is %#I:%M %p. Today is %A, %b the %#d."
Substitue="1":"1st"
Also, can I change AM and PM to Morning and Afternoon? What I want is "The current time is x:xx in the afternoon on monday, October the first.
It is currently May 28th, 2024, 6:26 pm
Substituting in date help
-
- Posts: 2
- Joined: October 1st, 2012, 9:34 pm
-
- Posts: 446
- Joined: August 7th, 2012, 9:18 pm
Re: Substituting in date help
you have to add the suffixes manually via a substitute
but you have to remember you use unique numbers as 1 isnt unique cause 11 can be substituted to 1st1st instead
therefore most its "01":"1st" or something like that
am/pm:
yes same via substitute if you got the AM/PM information already
but you have to remember you use unique numbers as 1 isnt unique cause 11 can be substituted to 1st1st instead
therefore most its "01":"1st" or something like that
am/pm:
yes same via substitute if you got the AM/PM information already
Powered by Sublime Text 3 with Rainmeter-Package
Re: Substituting in date help
Code: Select all
[MeasureDate]
Measure=Time
Format="The current time is %#I:%M %p. Today is %A, %b the %#d."
Substitute="the 1.":"the 1st.","the 2.":"the 2nd.", .....
alternatively have a look at RegExpSubstitute.
-
- Posts: 2
- Joined: October 1st, 2012, 9:34 pm
Re: Substituting in date help
Thanks for the help! I solved it