469,612 Members | 1,629 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,612 developers. It's quick & easy.

Currency values in Excel to VB2005

I am using the Microsoft Excel driver (DriverID 790) to process data in
an Excel spreadsheet. One of the columns is money, but was orinally
formatted as General. So a value in the spreadsheet of say 462.97 came
into the application as 462.969999999999, which is of course an invalid
value for currency, not only to say not the correct monetary value.
Changing the format of the cells to currency fixes the value and of
course looks fine in Excel. But now when I read the value in, it comes
in as 462.9700. Still an invalid currency value even if the extra
decimal places are always zero. So now I have to account for those
extra zeros and ignore them, which I do not like having to do. Is this
a known bug in the driver? Is it fixable? I tried all different
combinations of cell formatting I could think of, but nothing helps.

Mar 1 '06 #1
1 1476

<za***@construction-imaging.com> wrote in message
news:11*********************@i40g2000cwc.googlegro ups.com...
I am using the Microsoft Excel driver (DriverID 790) to process data in
an Excel spreadsheet. One of the columns is money, but was orinally
formatted as General. So a value in the spreadsheet of say 462.97 came
into the application as 462.969999999999, which is of course an invalid
value for currency, not only to say not the correct monetary value.
Changing the format of the cells to currency fixes the value and of
course looks fine in Excel. But now when I read the value in, it comes
in as 462.9700. Still an invalid currency value even if the extra
decimal places are always zero. So now I have to account for those
extra zeros and ignore them, which I do not like having to do. Is this
a known bug in the driver? Is it fixable? I tried all different
combinations of cell formatting I could think of, but nothing helps.


It's not really an invalid currency value. Have you tried pasting the value
into the cell?

Mar 3 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by Dave Stone | last post: by
6 posts views Thread by Darrell Wesley | last post: by
6 posts views Thread by gumbystation | last post: by
5 posts views Thread by Paul Miller | last post: by
reply views Thread by gheharukoh7 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.