You would benefit from reading the cocoa tutorials on apple’s website.
All you need to do is open your nib file and click the show assistant editor. Ctrl click the text field and drag it to the header file in the right window. Name the property and leave it as an outlet. This will create a property that you can use to access the text field.
solved Cocoa get textfield and get text from it [closed]