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.Display (Show) Legend in Pie Chart using ChartJS in AngularJS<p>Hi&nbsp;skp,</p> <p>Check this example. Now please take its reference and correct your code.</p> <p><strong><span style="text-decoration: underline;">HTML</span></strong></p> <div class="demo_block"> <pre class="brush: html">&lt;html xmlns=&#34;http://www.w3.org/1999/xhtml&#34;&gt; &lt;head&gt; &lt;title&gt;AngulrJS chart.js Pie chart Legend&lt;/title&gt; &lt;script type=&#34;text/javascript&#34; src=&#34;https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.7.8/angular.min.js&#34;&gt;&lt;/script&gt; &lt;script type=&#34;text/javascript&#34; src=&#34;https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.3.0/Chart.min.js&#34;&gt;&lt;/script&gt; &lt;script type=&#34;text/javascript&#34; src=&#34;https://cdnjs.cloudflare.com/ajax/libs/angular-chart.js/1.0.3/angular-chart.min.js&#34;&gt;&lt;/script&gt; &lt;script type=&#34;text/javascript&#34;&gt; var app = angular.module(&#39;MyApp&#39;, [&#34;chart.js&#34;]); app.controller(&#39;MyController&#39;, function ($scope) { $scope.quantity1 = 55; $scope.quantity2 = 46; $scope.quantity3 = 39; $scope.quantity4 = 71; var diskDataJson = { &#34;data&#34;: [$scope.quantity1, $scope.quantity2, $scope.quantity3, $scope.quantity4], &#34;labels&#34;: [&#34;0-30 days&#34;, &#34;31-60 days&#34;, &#34;61-90 days&#34;, &#34;91 days &amp; above&#34;], &#34;colours&#34;: [&#39;#36A2EB&#39;, &#39;#FF6384&#39;, &#39;#CC65FE&#39;, &#39;#FFCE56&#39;], &#34;options&#34;: { legend: { display: true, position: &#39;right&#39;} } }; $scope.pieDiskData = diskDataJson; }); &lt;/script&gt; &lt;/head&gt; &lt;body&gt; &lt;div ng-app=&#34;MyApp&#34; ng-controller=&#34;MyController&#34;&gt; &lt;canvas id=&#34;pie&#34; class=&#34;chart chart-pie&#34; chart-data=&#34;pieDiskData.data&#34; chart-labels=&#34;pieDiskData.labels&#34; chart-colors=&#34;pieDiskData.colours&#34; chart-options=&#34;pieDiskData.options&#34; width=&#34;245%&#34;&gt;&lt;/canvas&gt; &lt;/div&gt; &lt;/body&gt; &lt;/html&gt;</pre> </div> <p><a class="demo button orange btn btn-red">Demo</a></p>https://www.aspforums.net:443/Threads/153752/Display-Show-Legend-in-Pie-Chart-using-ChartJS-in-AngularJS/https://www.aspforums.net:443/Threads/153752/Display-Show-Legend-in-Pie-Chart-using-ChartJS-in-AngularJS/Fri, 26 Jul 2019 03:32:00 GMT