Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Decimal vs double
Message
General information
Forum:
ASP.NET
Category:
Other
Miscellaneous
Thread ID:
00745797
Message ID:
00745818
Views:
14
I am not sure about vb.net but in C# you need to suffix the value with M.
e.g.

dSalesAmount = 725.53M

123.45M
>Hi,
>
>I'am new to vb.
>
>I tried the following:
>
>Dim dSalesAmount AS Deciaml
>dSalesAmount = 0
>
>Dim dTotal AS Decimal
>dTotal = 0
>
>Works!
>dSalesAmount = 725
>
>Does not work!
>dSalesAmount = 725.53
>
>Decimal does not appear to support values like .0725.
>dTotal = SalesAmount * .0725
>
>The online help seems to state that it does support decimal places.
>
>What's Decimal and Double used for?
>
>Does VB automatically convert TextBox Controls to math if you use it in a calculation?
>
>Thanks
>Roland
- Jayesh
Previous
Reply
Map
View

Click here to load this message in the networking platform