相关疑难解决方法(0)

比较两个文本字段的文本

如何比较两个文本字段中的文本以查看它们是否相同,例如在"密码"和"确认密码"文本字段中?

if (passwordField == passwordConfirmField) {

    //they are equal to each other

} else {

    //they are not equal to each other

}
Run Code Online (Sandbox Code Playgroud)

cocoa-touch objective-c string-comparison uitextfield ios

3
推荐指数
2
解决办法
9517
查看次数