>Hi everybody,
>
>I can not figure out why this simple code is not working - when I type a number bigger than max, I can see the red border, but the error message is not shown instead of the label
>
>
><ng-form name="editPaDSSForm">
> <div class="form-horizontal">
> <div class="row">
> <div class="form-group">
>
> <div class="col-xs-6">
> <label class="control-label"
> ng-hide="(form.editPaDSSForm.maxDaysLocal.$error.max || form.editPaDSSForm.maxDaysLocal.$error.min) && form.editPaDSSForm.maxDaysLocal.$dirty"
> title="@Messages.maxAgeLocalSalespoint">@Messages.maxAgeLocalSalespoint</label>
> <label class="field-validation-error control-label-error animate-show"
> ng-show="(form.editPaDSSForm.maxDaysLocal.$error.max || form.editPaDSSForm.maxDaysLocal.$error.min) && form.editPaDSSForm.maxDaysLocal.$dirty">
> @String.Format(Messages.mustBeBetweenXandY, Messages.maxAgeLocalSalespoint, "1", "45")
> </label>
> <input type="number" name="maxDaysLocal"
> id="maxDaysLocal"
> min="1" max="45"
> ng-model="currentPrefs.loclccdays"
> class="form-control"
> placeholder="0"
> sm-focus
> data-sm:number-format data-sm:number />
> </div>
> </div>
>
> </div>
> </div>
></ng-form>
Shouldn't you be using 'ng-min' / 'ng-max' attributes for input ?