title: Pie chart: format value and percent independly
body: <p>I'm trying to format the DataLabel of a chart with thousands separator (dot) and two decimals in the percentage. Something like: "1.500; 66,66%".</p>
  
  <p>Recording a macro I see that the NumberFormat for dot as thousands separator is: <code>_-* #,##0_-;-* #,##0_-;_-* ""-""??_-;_-@_-</code> but I cannot format the DataLabels with it since then the percentage won't show up correctly.</p>
  
  <pre><code>ActiveSheet.Shapes.AddChart.Select    
  With ActiveChart
  Call .SetSourceData(v_range)
  .ChartType = xl3DPie
  .SeriesCollection(1).Name = p_title
  .SeriesCollection(1).ApplyDataLabels
  .SeriesCollection(1).DataLabels.Select
  End With
  With Selection
  .NumberFormat = "0.00%"
  .ShowPercentage = True
  .Separator = "" &amp; Chr(10) &amp; ""
  .ShowLegendKey = 0
  End With
  </code></pre>
  
  <p><strong>Edit:</strong>
  I think I need to clarify my problem. I'm creating this piechart automaticaly with a range my data, for example the count of A and the count of B, and I'm showing also the percentage, which the chart calculates. In the data range there are only A,B and the corresponing counts. What I have now can be seen in the image bellow.</p>
  
  <p><img src="https://i.stack.imgur.com/m2TBu.png" alt="Piechart I have now"></p>
  
  <p>What I wanted is this:</p>
  
  <p><img src="https://i.stack.imgur.com/vyFpI.png" alt="enter image description here"></p>
  
  <p>If there is no way to do it just with formating I guess i have to 'manually' calculate the percentage and 'manually' write the label with it. By manually I mean to access the <code>SeriesCollections(1).Points(1).DataLabel.Text = number + "\n" + percentage</code> or something like that.</p>