I have a price with two decimal places in a database i.e. 2.00, output this to the page and it displays 2.00 fine, but when I multiply this price by the quantity i.e 3 x 2.00 it is coming out as 600, when it should be 6.
The first response will give as the example above 600, the second will write 2.00, so it is clearly ignoring the decimal point.
Any ideas why? Thanks.
Code:
strProductTotal = rs("quantity") * cint(rs("productprice"))
response.write strProductTotal
response.write rs("productprice")
The first response will give as the example above 600, the second will write 2.00, so it is clearly ignoring the decimal point.
Any ideas why? Thanks.