Ganesh Kumar Palani Ganesh Kumar Palani - 1 year ago 92
iOS Question

How do i show Grid lines vertically in Core plot graph?

I have used Core Plot and i need to get the grid lines vertically,

  • List item

    I have tried custom labels in x axis

    x.labelingPolicy = CPTAxisLabelingPolicyNone;

But I didn't get the grid lines vertically.Can anyone help me with this?

enter image description here

Answer Source
//Add plot space

    CPTXYPlotSpace *plotSpace       = (CPTXYPlotSpace *)graph.defaultPlotSpace;

    plotSpace.delegate              = self;

    plotSpace.xRange = [CPTPlotRange plotRangeWithLocation:CPTDecimalFromInt(0.0) length:CPTDecimalFromInt(25)];

then change x axis label policy like this

x.labelingPolicy = CPTAxisLabelingPolicyFixedInterval;
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download