2010-07-10 50 views

回答

2

让它成为第一响应者。请参阅this link了解Apple的教程。

+0

像一个魅力工作 – 2010-07-10 08:56:03

+0

很高兴听到它。 – jer 2010-07-10 09:07:39

1

简单

[self.myTextView becomeFirstResponder]; 
0

调用对象是一个急救员将做到这一点。但我花了几分钟的时间找出最好的分配它.. 最后!

[UITextFeild becomeFirstResponder]; 

如果您有例如动画的UIView,它分配的图绘后。

[UIView animateWithDuration:0.9 
animations:^{ 
    UIView.frame = newFrame; 
} 
completion:^(BOOL finished){ 
    [UIView animateWithDuration:0.9 
     animations:^{} 
     completion:^(BOOL finished){ 
     [UITextFeild becomeFirstResponder];// << Right here.. 
    }]; 
}]; 
相关问题