首页 > 代码库 > IOS 获取文本焦点 主动召唤出键盘(becomeFirstResponder)

IOS 获取文本焦点 主动召唤出键盘(becomeFirstResponder)

 

 

- (void)viewDidAppear:(BOOL)animated
{
    // 3.主动召唤出键盘
    [self.nameField becomeFirstResponder];
    //    [self.nameField resignFirstResponder];
}

 

IOS 获取文本焦点 主动召唤出键盘(becomeFirstResponder)