简体   繁体   English

如何使用objective-C验证由UITableViewCell在自定义文件中创建的多个自定义UItextfield值

[英]How to validate a multiple custom UItextfield value which is created by UITableViewCell in custom file using objective-C

I have created an outlet for UItextfield in a custom.h file and created 3 UITextfields using tableviewcell and also assigned tag to each of the textfields.我在 custom.h 文件中为 UItextfield 创建了一个插座,并使用 tableviewcell 创建了 3 个 UITextfields,并为每个文本字段分配了标签。 But I don't know how to get those textfield values and also validate them.但我不知道如何获取这些文本字段值并验证它们。 When all the Textfield values are correct, it should show successful alert message when clicked on a button.当所有 Textfield 值都正确时,它应该在单击按钮时显示成功的警报消息。 I don't want to use 3rd party libraries.我不想使用 3rd 方库。

Add a listener to the textfield field change in the cell and create a delegate that is held by the controller.向单元格中的文本字段字段更改添加一个侦听器,并创建一个由控制器持有的委托。 When creating a cell, you need to add a flag to the cell.创建单元格时,需要为单元格添加标志。 When the proxy method is implemented, the correctness of the field of the textfiled is determined.实现代理方法时,确定textfiled 字段的正确性。 The created flag is used to distinguish the cell from the textfield and recorded in the nsarray. created 标志用于区分单元格和文本字段并记录在 nsarray 中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何将自定义 UITableViewCell 添加到 xib 文件中 - How to add a custom UITableViewCell to a xib file objective-c 如何从自定义UItableViewCell获取UITextfield值。 如果UITableviewCell具有多个UITextFields而不使用标签属性 - How to get UITextfield value from custom UItableViewCell. If UITableviewCell have multiple UITextFields without using tag property Objective-C:应用范围内完全可重用的自定义UITableViewCell - Objective-C: App-wide fully reusable custom UITableViewCell Objective-C:获取不可见自定义 UITableViewCell 上的属性值 - Objective-C: Getting Value of Property on Non-Visible Custom UITableViewCell 如何在目标C中创建UITextField的自定义委托 - How to create Custom Delegate of UITextField in Objective C 使用Xcode 7使用UITextfield自定义UITableViewCell - Custom UITableViewCell with UITextfield using Xcode 7 在自定义Swift框架中的Objective-C文件上使用Swift - Using Swift on Objective-C file in custom Swift framework 如何在Objective-c的自定义UITableViewCell中更改UIButon文本属性 - How do you change the UIButon text attribute in a custom UITableViewCell in Objective-c 如何在Objective-C中获取UIAlertView子视图UITextField值 - How to get an UIAlertView subview UITextField value in Objective-C 使用objective-c自定义UIView - custom UIView using objective-c
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM