Jump to content

Adding st, nd, rd or th to a date


geeool

Recommended Posts

Does anyone have a snippet of code for adding a postscript to a date? What I mean is instead of May 1, I want it to display as May 1st. May 2 would be May 2nd, May 3 would be May 3rd, etc. I am using a calendar to select the date and the format is MMDDYYYY.

 

I am currently using the following for formatting:

 

return FormatDate(Field("Event Date"), "ld, lm d");

 

Any help is greatly appreciated.

 

Thanks,

Joel

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...