View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
kirkm[_8_] kirkm[_8_] is offline
external usenet poster
 
Posts: 166
Default VB Format command fails


Hi,

Anyone know what's wrong here?

Cell(1,1) contains "00/11/1975" as text.

Dim v as Date
v = Format(.Cells(1, 1), "mmm yyyy")

If v is dimmed as a Variant the format is unchanged
and in the above example returns 'type mismatch'.

Have spend a long time trying all sorts of variations
without success.

Thanks - Kirk