Reputation: 467
I have downloaded this code from Github : https://github.com/gilthonweapps/CorePlotBarChartExample .How to get onTap for bar selected ? I am using the following code:
#pragma mark - CPTBarPlotDelegate methods
-(void)barPlot:(CPTBarPlot *)plot barWasSelectedAtRecordIndex:(NSUInteger)index {
NSLog(@"barWasSelectedAtRecordIndex %d", index);
}
But this is not working (Its not recognizing the Tap).Please Help. Thanks in Advance and Happy New Year.
Upvotes: 2
Views: 532
Reputation: 27381
Set the plot delegate
to your bar plot delegate object. This is usually the view controller but it does not have to be.
Upvotes: 5