Jump to content

Simple String To Date Question


Jonah

Recommended Posts

I have dates like "8/27" or "9/4", and I need to convert them to date objects.

 

When choosing a year, we should go backwards until we find the first match.  That is, if the script runs on Jan 1, 2008 and encounters the string "8/27", it should return a date for "8/27/2007".

 

I've been playing around with strtodate and some other functions but I can't figure this out, and as there must be a simple solution I'd like to avoid writing a custom function.

 

Thanks for any help,

Jonah

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  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...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.