0

in SQL server I have the field:

Price   decimal (12,4)

in MVC model:

public decimal? Price { get; set; }

When I add or edit price 1.1234 it will save 1.1200 in the database. I want to save it as it is 1.1234

SynozeN Technologies
  • 1,337
  • 1
  • 14
  • 19
Ayman
  • 23
  • 7

1 Answers1

0

you need to add like this -

 dataItem.OtherFields["Price"].ToString("0.00000")

for more you can check out this

Community
  • 1
  • 1
tom
  • 3,720
  • 5
  • 26
  • 48