How to set range validation in AngularJS
<p>I want to set range validation i.e i want salary should be between 100000-20000000. I used ng-min and ng-max. But still its not throwing error message. here is what i have done. Its only checking number validation.  </p>

<pre><code>&lt;input ng-model="name2" name="name2" type="text" class="zoomIn" ng-min="100000" ng-max="20000000" ng-pattern="/^\d+$/" placeholder="Your Annual Net Profit" required&gt;
&lt;div ng-messages="step5form.name2.$error"&gt;
&lt;div ng-message="min"&gt;Please enter a value between 100000 and 20000000.&lt;/div&gt;
&lt;div ng-message="max"&gt;Please enter a value between 100000 and 20000000.&lt;/div&gt;
&lt;div ng-message="pattern"&gt;Annual net profit cannot be characters.&lt;/div&gt;
&lt;/div&gt;
</code></pre>