Skip to content

Instantly share code, notes, and snippets.

@rrodrigueznt
Created October 6, 2019 09:25
Show Gist options
  • Save rrodrigueznt/cdf1943309eb0ea5e7e0473f71fde57e to your computer and use it in GitHub Desktop.
Save rrodrigueznt/cdf1943309eb0ea5e7e0473f71fde57e to your computer and use it in GitHub Desktop.
Superscript, too, is possible! You can use a field coded as:
{QUOTE{SET MergeDate {MERGEFIELD Date}}
{MergeDate \@ "dddd 'the' d"}
{IF{=(MOD({={MergeDate \@ d}+89},100)>2)*(MOD({={MergeDate \@ d}+9},10)<3)}= 1 {=MOD({MergeDate \@ d},10)-2 \# rd;st;nd} th}
{MergeDate \@ "' of' MMMM, yyyy"}
}
IF Expression1 Operator Expression2 TrueText FalseText
IF {MergeDate @\ d}
{IF{=(MOD({={MergeDate \@ d}+89},100)>2)*(MOD({={MergeDate \@ d}+9},10)<3)}= 1 {=MOD({MergeDate \@ d},10)-2 \# rd;st;nd} th}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment