How to set default value for Html.TextBoxFor in ASP.NET MVC ?


This content was proof-read by Grammarly. You can Try Grammary for FREE

You can set the default value for the Html.TextBoxFor extension controls in ASP.NET MVC by specifying the Value property as shown below.

How to set default value for Html.TextBoxFor in ASP.NET MVC ?

<%= Html.TextBoxFor(x => x.Age, new { @Value = "0"}) %>


Are you a .NET Developer planning to integrate GraphQL for .NET in your Application? Check out this book BUY & DOWNLOAD GRAPHQL.NET COOKBOOK
%d bloggers like this: