if someone could give me some hint I would appreciate.
I'm searching for a while, and I even found a post I thought it would solve my problem, but it didn't.
Disable Required validation attribute under certain circumstances
Basically I have a simple User.cs model where I have username, FirstName, LastName and SignupDate
All have the required annotation and I would like to solve this without erasing the Required tag.
After I generate the view, I erase in the view the html code for the SignupDate:
 <div class="editor-label">
        @Html.LabelFor(model => model.SignupDate)
 </div>
    <div class="editor-field">
        @Html.EditorFor(model => model.SignupDate)
        @Html.ValidationMessageFor(model => model.SignupDate)
 </div>
When I click submit it does not work.
Also if I do the suggested in the other post
<div class="editor-label">
        @Html.LabelFor(model => model.SignupDate)
</div>
<div class="editor-field">
       @Html.TexBoxFor(model => model.SignupDate, new { data_val = false })
</div>
If I leave it as blank also does not work..
Any suggestions? Thanks!!
 
     
     
    