chrisnolten
chrisnolten

Reputation: 111

ArrayController cannot find AppDelegate (Bindings in Cocoa)

I am just starting to learn about bindings. In the tutorials I have found, someone is connecting an ArrayController to AppDelegate by simply picking AppDelegate from the list that can be found under the bindings-options of the ArrayController. When I try to do the same, AppDelegate is not included in the list.

What am I doing wrong here? (I am usingh objective-c btw)

Upvotes: 0

Views: 255

Answers (1)

Anoop Vaidya
Anoop Vaidya

Reputation: 46533

Make sure you have selected the correct object i.e. ArrayController.

Please refer the screen shot: enter image description here

FYI, check if you missed something from these steps:

Step 1: Create an instance of ArrayController under Objects section.

Step 2: Select it, and go to the Binding Inspector.

Step 3: In Controller Content, select Content Array's Bind To.

Step 4: In this pop up you could see, as shown above.


Or, other cases may be you have created a new Window in your project. There you can not see the AppDelegate.

In such case set the File's Owner's class to AppDelegate or some other class from where you want to pick the array.

enter image description here

Then select the array controller and set in content to File's Owner.

enter image description here

Note: In the screen shots I am using View-based table view.

Upvotes: 2

Related Questions