ASPForums.Net RSS Feedhttp://www.aspforums.net/Handlers/RSS.ashxLatest additions to the content that appears on ASPForums.Net(c) 2019 www.aspforums.com. All rights reserved.Using Angular Material DatePicker control in AngularJS<p>Hi&nbsp;sanvi,</p> <p>For not not accepting future Dates use md-max-date.</p> <p>Refer the below example.</p> <p><strong><span style="text-decoration: underline;">HTML</span></strong></p> <div class="demo_block"> <pre class="brush: html">&lt;link rel=&#34;stylesheet&#34; href=&#34;https://cdnjs.cloudflare.com/ajax/libs/angular-material/1.0.4/angular-material.css&#34; /&gt; &lt;script type=&#34;text/javascript&#34; src=&#34;https://ajax.googleapis.com/ajax/libs/angularjs/1.4.4/angular.js&#34;&gt;&lt;/script&gt; &lt;script type=&#34;text/javascript&#34; src=&#34;https://ajax.googleapis.com/ajax/libs/angularjs/1.4.4/angular-animate.min.js&#34;&gt;&lt;/script&gt; &lt;script type=&#34;text/javascript&#34; src=&#34;https://ajax.googleapis.com/ajax/libs/angularjs/1.4.4/angular-aria.min.js&#34;&gt;&lt;/script&gt; &lt;script type=&#34;text/javascript&#34; src=&#34;https://cdnjs.cloudflare.com/ajax/libs/angular-material/1.0.4/angular-material.js&#34;&gt;&lt;/script&gt; &lt;script type=&#34;text/javascript&#34; src=&#34;https://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular-messages.min.js&#34;&gt;&lt;/script&gt; &lt;script type=&#34;text/javascript&#34; src=&#34;https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.10.2/moment.min.js&#34;&gt;&lt;/script&gt; &lt;script type=&#34;text/javascript&#34;&gt; var app = angular.module(&#39;MyApp&#39;, [&#39;ngMaterial&#39;]); app.controller(&#39;MyController&#39;, function ($scope) { $scope.data = { date: new Date() }; $scope.submit = function () { $scope.data.dateString = moment($scope.data.date).format(&#34;DD/MM/YYYY&#34;); } $scope.maxDate = new Date(); }).run(); &lt;/script&gt; &lt;div ng-app=&#34;MyApp&#34; ng-controller=&#34;MyController&#34;&gt; &lt;md-datepicker ng-model=&#34;data.date&#34; md-placeholder=&#34;Choose a date&#34; md-max-date=&#34;maxDate&#34;&gt;&lt;/md-datepicker&gt; &lt;md-button ng-click=&#34;submit()&#34; class=&#34;md-primary&#34; type=&#34;button&#34;&gt;Submit&lt;/md-button&gt; &lt;p&gt; Selected Date is : {{data.dateString}}&lt;/p&gt; &lt;/div&gt;</pre> </div> <p><a class="demo button orange btn btn-red">Demo</a></p>https://www.aspforums.net:443/Threads/174619/Using-Angular-Material-DatePicker-control-in-AngularJS/https://www.aspforums.net:443/Threads/174619/Using-Angular-Material-DatePicker-control-in-AngularJS/Fri, 14 Dec 2018 02:36:42 GMT