I have created a VF pie chart which is displaying the data dynamically. I need to remove the labels on pie chart which are being highlighted on the attached image as the data with large text is getting overlapped. Here is the code.
Page-
<apex:pageBlock id="PositionData" >
<apex:chart height="450" width="550" data="{!PieData}" >
<apex:pieSeries tips="true" dataField="pdata" labelField="name"/>
<apex:legend position="right"/>
</apex:chart>
</apex:pageBlock>
Controller-
public List<PieWedgeData> getPieData()
{
List<PieWedgeData> pdat = new List<PieWedgeData>();![enter image description here][2]
List<Position__c> post = [SELECT ID, Product_New__c, Product__c, Quantity__c, Contact__c FROM Position__c WHERE Contact__c = :selectedName];
for(Position__c temp : post)
{
if(temp.Product_New__c !=null && temp.Quantity__c !=null)
{
pdat.add(new PieWedgeData(temp.Product_New__c, temp.Quantity__c));
}
}
return pdat;
}
// Wrapper class
public class PieWedgeData
{
public String name { get; set; }
public Decimal pdata { get; set; }
public PieWedgeData(String name, Decimal pdata)
{
this.name = name;
this.pdata = pdata;
}
}