Hi
I have a form that holds a textfield, this textfield get its value from a sql server database, and the datatype for that specifik column is ...
Decimal
Precision: 18
Scale: 2
When I then try to update that value with the textfiled from the form, a value can for example look like this...
125,5
And when I try to insert the value in the database with this ...
MyCommand.Parameters.Add("@Price", SqlDbType.Int, 4).Value = iProductPrice
I get an error telling me.. input value is in wrong format..
Is the SqlDbType wrong or what should I change to get it to work?
Regards
I have a form that holds a textfield, this textfield get its value from a sql server database, and the datatype for that specifik column is ...
Decimal
Precision: 18
Scale: 2
When I then try to update that value with the textfiled from the form, a value can for example look like this...
125,5
And when I try to insert the value in the database with this ...
MyCommand.Parameters.Add("@Price", SqlDbType.Int, 4).Value = iProductPrice
I get an error telling me.. input value is in wrong format..
Is the SqlDbType wrong or what should I change to get it to work?
Regards