I have a tableview with multiple dynamic tableview cells, and inside each tableviewcell i have multiple textfields. Each cell has a different tag, but the texfields don´t! and i need to retrieve the information the user will insert later on them. I´m using the interface builder.
Is it possible to access a texfield that isn´t tagged?.
Can i manage this using the “user defined Runtime Attributes”?.
Thanks
This is a common mistake when starting with iOS.
You should not be referring directly to the textfield in order to retrieve the information stored in it, especially in a table view. In a table view, when a cell scrolls off the screen, the cell will very likely get reused and the information that was stored there is gone forever.
Instead, store the text when the user finishes editing the textfield by setting your view controller as the textfield delegate and then implementing the
textFieldDidEndEditing:delegate method: