开发者

how to append the value from picker to textfield

开发者 https://www.devze.com 2022-12-11 20:45 出处:网络
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 single 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 single textfield.

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.

0

精彩评论

暂无评论...
验证码 换一张
取 消