• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

VB.NET throws up on 999999999999999999999

SoftwareEng

Senior member
'Double' data type is hacking up my numbers.
(aka I'm in ur code, hacking up ur doublez)

Dim dbl As Double = 999999999999999999999.99

As soon as enter this statement, VB.NET (2005) replaces it with:

Dim dbl As Double = 1.0E+21.

Not cool, I need exactly the number I entered! Manual says, "A Double value has 15 decimal digits of precision". How can I store larger floating-point numbers?

thanks =)
 
I think that the Decimal datatype is more precise, but you're still going to have issues when you get to a very large precision.
 
Originally posted by: Tencntraze
I think that the Decimal datatype is more precise, but you're still going to have issues when you get to a very large precision.

nice! I thought Decimal only supported integer numbers, but it looks like it takes floating points as well.
 
Back
Top