iOS 6 UIView properties yield 0 -


i'm trying very, simple , doesn't work; seems i'm missing fundamental. have single-view application. there's image in center. i'd move user touch. problem is, cannot retrieve coordinate values image. here's do:

i have uiimageview in storyboard , it's centered image file loaded.

i make outlet image view in viewcontroller's header file:

@property (weak, nonatomic) iboutlet uiimageview *imageview; 

and naturally, it's connected imageview in storyboard.

in viewcontroller's implementation file, in view did load have this:

[super viewdidload]; cgpoint center = self.imageview.center; nslog(@"center: %f, %f", center.x, center.y); 

the results have in console are, unfortunately, both 0. image view owned main uiview of viewcontroller. there seems very, fundamental problem can't figure out. help!

did connect imageview storyboard outlet in code ctrl drag storyboard code?


Comments