how to append the value from picker to textfield
I am having a picker, which displays data from 2 arrays, say like it is a picker with 2 sections.
Now I w开发者_如何学Cant the selected values from both the sections, to appear in a singletextfield
.
I tried with
textField.text=[[First_Array ObjectAtindex:row]appendString:[Second_Array ObjectAtIndex:row]];
But it gives error “Void Value not ignored as it ought yo be”
Instead of appendString:
, use stringByAppendingString:
. appendString:
is used to modify an NSMutableString
in place, it doesn't return a value.
精彩评论