View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.programming
Christian[_5_] Christian[_5_] is offline
external usenet poster
 
Posts: 6
Default Strip date from string and transfer datetext to number

Hi,
Yes I tested this and could not get it to work either.
I get the same result as with my formula:

"=VALUE(CONCATENATE(LEFT(RC[-4],2),""-"",MID(RC[-4],3,3),""-"",MID(RC[-4],6,
4)))"

- Chr

"Ron Rosenfeld" wrote in message
...
On Sat, 3 Jul 2004 09:27:07 -0500, MSP77079
wrote:

myDate = Datevalue(Left("04Oct20040000", 9))


Did you test that? I can't seem to get it to work on my machine.

On my computer, using VBA 6.3, Datevalue does not seem to work in the

absence
of some kind of separator between the components. I get Type Mismatch

error
with your function.

But even with the spaces, I still get a Type Mismatch error if regional
settings are set to Danish:

?Datevalue(Left("04 Oct 20040000", 11)) gives Type Mismatch error.


--ron