IOS Array from text field -


i'm building ios app. want user input 2 options text field. 1 of options later randomly displayed in label. i'm thinking text field should log information in nsmutablearray can later call on. information needs temporarily stored because go away after randomly displayed in label.

i'm not sure how create array text field. appreciated.

is looking for?

int choice = rand() % 2;  nsstring* result;  if (choice == 0)     result = textfield1.text; else     result = textfield2.text;  .... label.text = result; 

Comments