• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Date Format from a string

Portucale

Member
Hi,
I have a rawdata file which outputs in the date column formatted as Text the month (May-14 ), is there any way that I can format the same May-14 to a date format "mmm-yy"?

Any help and All help is very much appreciated.

Thanks,
 
Sorry, should have mention that, yes I did, and yes it works, but this is to an automated report with no intervention from the users, so I was looking for a possible macro or a function.

Thanks,
 
Hi,
Can't this action(Text to Columns) be automated? I tried doing it with macro recorder and got this code.
Code:
Option Explicit

Sub TextToDate()

    With Selection
        .TextToColumns , DataType:=xlDelimited, FieldInfo:=Array(1, 3)
        .NumberFormat = "mmm yy"
    End With
   
End Sub
 
Back
Top