Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
I'm converting text to date cells using a combination of NumberFormat and TextToColumn calls. However, certain values are not being converted and are remaining, I think, as text For example ' ---- format each date column as date For l_nCol = 1 To .Cols If .IsDate(l_nCol) Then ' .Format contains formats e.g. mm/yy, dd-mmm-yyyy for each column l_oSheet.Columns(l_nCol).NumberFormat = .Format(l_nCol) l_oSheet.Columns(l_nCol).TextToColumns FieldInfo:=Array(1, 4) End If Next l_nCol 06/10/1998 gets correctly formatted to 06/Oct/1998 but 27/03/1998 doesn't get formatted and remains as it is as text (it is left justified, whereas converted date values are right justified) Can someone please explain where I'm going wrong ... Many thanks Simon |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
What does TrailingMinusNumbers do in the TextToColumns Method | Charts and Charting in Excel | |||
texttocolumns | Excel Programming | |||
TextToColumns | Excel Programming | |||
TextToColumns Dialog | Excel Programming |