ios - Expression is not assignable error -
- (void)textfielddidbeginediting:(uitextfield *)textfield { #define koffset_for_keyboard 110.0 textfield.frame.origin.y -= koffset_for_keyboard; textfield.frame.size.height += koffset_for_keyboard; textfield.frame = cgrectmake(textfield.frame.origin.x, (textfield.frame.origin.y - 230.0), textfield.frame.size.width, textfield.frame.size.height); }
got code textfield app in ios... plan have in way that, when keyboard appears, textfield goes on top of keyboard , when return key in keyboard pressed, textfield goes original position @ bottom of screen. error, "expression not assignable." how solve this? error mean?
you can't assign value origin or height. you'll have assign cgrect frame , update values in new cgrect.
Comments
Post a Comment