Saturday 15 February 2014

sql - Remove default 0 from numeric textbox -


There is an EditorFor in my model that is not connected to a blank numeric field in a database. I want to keep this area empty so users can enter or scan numbers in the area. Unfortunately, it misses 0. What is an easy way to remove 0 while keeping the field blank?

  @ Html.EditorFor (model = & gt; Rectangle, new {id = "RackNumber"})    

Modify the model property type to clear: public int? Rack number {get; Set;}

No comments:

Post a Comment