int to numeric numeric(18,2) ?

J

jobs

I have a column that is numeric(18,2) in sql server.

what type should I use in my sqldatasource parameter in asp.net?
<asp:parameter Name="CreditLimit" Type="Int32" />


what type should I use in my vb.net method that updates this?
ByVal CreditLimit As Integer

What type should I use in my
parameters.Add("@CreditLimit", SqlDbType.Int).Value = CreditLimit

The list combinations do not work as on the way to to the database I
can't send 50.00, but if I enter 50 I do get 50.00 back.

Clearly something I've overlooked, I dont see type numeric or money..?
 
B

Brandon Gano

Have you tried using the Decimal type in your code? For example (not
tested):

<asp:parameter Name="CreditLimit" Type="Decimal" />

ByVal CreditLimit As Decimal
 

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

Forum statistics

Threads
473,734
Messages
2,569,441
Members
44,832
Latest member
GlennSmall

Latest Threads

Top