hello,
I have view with textbox and I have given @Value to that textbox as 15 by default. Please refer textbox below :
@Html.TextBoxFor(Model => Model.quantity, new { @id = "txtquantity", @type = "number", @class = "form-control", @Value = "15" })
I am able to save that or any other value in SQL DB.
But when I edit that textbox, it should bind the value which is saved in a database, but still it binds that by default "15" value, even in db the value is saved different.
Anything can be done to make this work?
Thank you in advance!

Kiran MohantyRank #821 · 2.8K reputationPosted Feb 15, 2021, 6:21 AM EST
Guest UserRank #2,192 · 643 reputationPosted Feb 15, 2021, 6:49 AM EST
Sachin SinghRank #66 · 26.2K reputationPosted Feb 15, 2021, 9:04 AM EST
Guest UserRank #2,192 · 643 reputationPosted Feb 15, 2021, 10:23 AM EST
Sachin SinghRank #66 · 26.2K reputationPosted Feb 15, 2021, 12:36 PM EST
Guest UserRank #2,192 · 643 reputationPosted Feb 16, 2021, 8:02 AM EST
Sachin SinghRank #66 · 26.2K reputationPosted Feb 16, 2021, 8:06 AM EST
Rijwan AnsariRank #82 · 24.2K reputationPosted Feb 16, 2021, 8:18 AM EST
Satya KarkiRank #78 · 24.6K reputationPosted Feb 16, 2021, 10:57 AM EST
Guest UserRank #2,192 · 643 reputationPosted Feb 20, 2021, 10:14 AM EST
Guest UserRank #2,192 · 643 reputationPosted Feb 20, 2021, 10:17 AM EST
Sachin SinghRank #66 · 26.2K reputationPosted Feb 20, 2021, 10:22 AM EST