I have declared a CGFloat variable on my header file:
@property (nonatomic)CGFloat *heightOfSection;
Synthetized it on my implementation file, but it gives me an error trying to assign a value to it:
// Set height of section
heightOfSection = 45.0f;
This is the error shown:
Assigning to 'CGFloat *' (aka 'float *') from incompatible type 'float'
Any idea to solve the issue?
CGFloat
is a primitive type, not an object type. Your property should be declared like this:
@property (nonatomic) CGFloat heightOfSection;
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