View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
kmbarz kmbarz is offline
external usenet poster
 
Posts: 16
Default Getting Month Name

I've tried a few different ways in this macro to get the 05 to resolve to
"May" (06="June",...) but it still seems to want to remain as "05". What am
I missing here?

Sub LoadData(dt As String) 'dt comes in like 0505

mmyy = Trim(dt)
fulldate = Mid(mmyy, 1, 2) & "/01/20" & Mid(mmyy, 3, 2)
MsgBox (Format(Month(fulldate), mmm))