The topic says everything. why i get this error message at this 2 lines?
NSArray *coordinates = [locationDetails[@"coordinates"] componentsSeparatedByString:@","];
CLLocationDegrees *lat = [coordinates[1] doubleValue]; //here is the red arrow <----
and exactly this message will appear:
Initializing 'CLLocationDegrees *'(aka 'double *') with an expression of incompatible type 'double'
Change this:
CLLocationDegrees *lat = [coordinates[1] doubleValue];
to:
CLLocationDegrees lat = [coordinates[1] doubleValue];
Get rid of the asterisk. CLLocationDegrees
is not a class, it is a typedef for double
(a basic type).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With