Date Concatenation

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am trying to first strip the month using 2 digits for example January would
be 01, then strip the year using 2 digits for example 06.

My concatenation is working, however, I get 32006 and I want to see 0306.

My test code so far is,

Dim str As String

str = Month(Date) & Year(Date)

but I need to customize the month and year formats, the functions don't
allow added parameters, it only accept (Date).
 
I don't think you can customize the month/date/year functions, but you could
use the format function.
str = Format(Date, "mmyy")
 
Back
Top