Using Dates in Snippets: Get the Advanced Dates Group

Advanced date Snippets go beyond basic date math to expand dates like next Monday or the last day of the month. Get the free Past and Future Dates group for TextExpander and see how to customize its date formats.

Calendar icon with the TextExpander logo on a blue patterned background, labeled #TextExpanderBlog

TextExpander has many features anyone can use, from autocorrecting your brand’s names to full document outlines with fill-in-the-blank sections.

But if you are interested in more advanced uses, TextExpander also supports scripting. If you know how to JavaScript, go for it. Our Tips page has links to our blog posts about scripting. If you’re interested but not a scripter yourself, examples are included to help you along.

Sometimes we take some of these advanced snippets and create a group for our Public Groups so that anyone can use them. That’s the case in the latest group we’ve created, free for you to use:

Past and Future Dates

You can expand the current date or time in a snippet, saving you from having to look it up on the calendar. This is, in fact, a default snippet you get with TextExpander, just type ddate.

But beyond that, you can also expand dates in the future or past. Read how in our post TextExpander Tips: Text snippets for typing dates for today, the future, and yesterday.

While expanding the date for “5 days ago” may be perfect for you, maybe you want to expand the date for “Last day of the month” or “Next Monday.” That isn’t so easy with the standard date math options. You have to account for weekends, for which day it is today and how many days are in this month. Not so simple as “2 days from now.”

But it is possible with JavaScript, and that’s how the Past and Future Dates group was created.

Get this group, and you can expand a wide array of date types. And, if you’re feeling a bit adventurous, you can learn how to customize them in our post Past and Future Dates with TextExpander, Revamped.

This post will show you how to set new date formats to whatever you need, from December 22, 2017, to file naming friendly 2017_12_22. You can even select a different location in the world to be your timezone.

Do you use dates in snippets? What kind of date options would you like? Let us know @TextExpander and on Facebook.

Keep reading

View all posts →
TextExpander 7.8 featured Explore TextExpander TextExpander 7.8: Snippet Creation, Team Management, and Searching is Easier Than Ever write medical progress notes faster Explore TextExpander How To Write Medical Progress Notes Faster A woman sat at a desk creating an invoice Explore TextExpander How to Make Invoicing Easier: Tools, Tips and Templates
Using Dates in Snippets: Get the Advanced Dates Group