Add new values to Access Double fields - x100

M

Mark

Hi - I've got a really strange problem I can't explain - when I add new
values into my database (Access) ir multiplies them by 100 - for example
id I enter the values:

10.50
7.50
5.50

They go into the database as:

1050
750
550

The field in Access is a Double type, nullable, and set to default to 0.

My code to add it is:
(the response.writes are what product the numbered output above - so I
know what the form is posting, and subsequently what the database has in
its fields)

if Request("selected") <> "" then
response.write(Request("RetailPrice"))
response.write("<br>")
response.write(Request("Price"))
response.write("<br>")
response.write(Request("CostPrice"))
response.write("<br>")
ProductsRS.AddNew
ProductsRS("Product")=Request("Product")
ProductsRS("Description")= Request("Description")
ProductsRS("StockNumber")=Request("StockNumber")
ProductsRS("CategoryID")= Request("CategoryID")
ProductsRS("RetailPrice")=Request("RetailPrice")
ProductsRS("Price")=Request("Price")
ProductsRS("CostPrice")=Request("CostPrice")
ProductsRS.Update
ProductsRS.Requery
ProductID=ProductsRS("ProductID")
response.write(ProductsRS("RetailPrice"))
response.write("<br>")
response.write(ProductsRS("Price"))
response.write("<br>")
response.write(ProductsRS("CostPrice"))
response.write("<br>")

Can anyone please try and help me with this.

Kind regards, Mark
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,008
Latest member
obedient dusk

Latest Threads

Top