Why does the VBA format function work like this?

vba

Solution

`0.041667` is `1/24`so its interpreting `1A` as `1 AM`

?cdate(Format("1A","0.000000") )
01:00:00 

Pass `"1A"` to `val()` to extract `1` if that what you want else don't call format if the input is not numeric.

Problem

Why does Format("1A","0.000000") return 0.041667?

Original source