You will need to change you text field to an instance of NSComboBox. Then, create your NSArray (or of course mutable array) of strings, and send it to the combo box like this:
Code:
[myComboBox addItemsWithObjectValues:listOfStrings];
If you want to sort the list alphabetically, you do it like this:
Code:
[listOfStrings sortUsingSelector:@selector(caseInsensitiveCompare:)];
Obviously do that before using the addItemsWithObjects method above.
To clear the list of completions in a combo box, use this method:
Code:
[myComboBox removeAllItems];
Hope that helps.