ios - why can this code not access 'borderWidth' (iphone code attached) -
ios - why can this code not access 'borderWidth' (iphone code attached) -
why can code not access 'borderwidth' (iphone code attached)
this based on simple test project, did add together quartzcore framework didn't help. still throwing error, see code below. project works fine , can't see difference
#import "customview.h" @implementation customview - (id)initwithcoder:(nscoder *)coder { self = [super initwithcoder:coder]; if (self) { // ui layout self.layer.borderwidth = 5; // error error: accessing unknown 'borderwidth' component of property } homecoming self; }
you need add together quartzcore framework in order access layer property of uiview. did add together ?
add framework next steps if using xcode 4
1. select target 2. build phases 3. link binary library section 4. tap + , find quartz 5. add together framework.
now, import ever want access layer property of uicontrol.
#import <quartzcore/quartzcore.h>
hope help.
iphone ios uiview xcode4 calayer
Comments
Post a Comment