title: Values in a pie chart
body: <p>How do you display the values of each pie in a pie chart using ChartHelper?  I am using MVC3/Razor syntax.</p>
  
  <p>Trying to do something like this:</p>
  
  <p><img src="https://i.stack.imgur.com/J8vKu.jpg" alt="Pie"></p>
  
  <p>The image is from <a href="http://www.asp.net/web-pages/tutorials/data/7-displaying-data-in-a-chart" rel="nofollow noreferrer">this tutorial</a> for ChartHelper in MVC:</p>
  
  <p>My code:</p>
  
  <pre><code>var bytes = new Chart(600, 300).AddSeries(
                      chartType: "pie",
                      legend: "Sales in Store per Payment Collected",
                      xValue: viewModel.SalesInStorePerPaymentCollected.XValues,
                      yValues: viewModel.SalesInStorePerPaymentCollected.YValues
                      )
                      .GetBytes("png");
  
  
              return File(bytes, "image/png");
  </code></pre>