I installed the Chart library (version 3.0.1) (https://github.com/danielgindi/Charts) in my objective-C
project. In the previous version of my code, below line works successfully,
BarChartDataSet *set12 = [[BarChartDataSet alloc] initWithYVals:yvals label:@"Water Consumed"];
In latest version of charts i.e 3.0.1, the above line results in build error:-
No visible @interface for 'BarChartDataEntry' declares the selector 'initWithValue:xIndex:'
I've BarChartDataSet
class and there is no such method. What will be the replacement of this method in objective-C?
You need to use below method for BarChartDataSet
BarChartDataSet *set1 = [[BarChartDataSet alloc] initWithValues:yVals label:@"Quarter Share"];
Just Replace initWithYVals
to initWithValues
.