Connecting file owner to app delegate-Collection of common programming errors

This was driving me nuts also.

I marked +1 above, the answer does in fact help, the answer is cryptic, so this will help explain in finer detail how to get a delegate or another connection that won’t link directly into the file using the “Assistant Editor” view.

right click = control key + left click.!

IN XCode 4. Select any of your XIB files. Say for a UIScrollView you added, you want to set the Delegate for it. Well unlike the prior IB where you just open up connections inspector, and drag a connection to the file. Its actually just the same here. BUT a difference.

(NOTE:The dock is panel 2 from the left. Only with a XIB open) Open up the Dock > http://developer.apple.com/LIBRARY/IOS/#documentation/ToolsLanguages/Conceptual/Xcode4UserGuide/InterfaceBuilder/InterfaceBuilder.html

There is a small triangle arrow there at the bottom of the Dock.

At the very top of the Dock is “Files Owner”, without the dock opened, it is the white box with orange trim.

Select the view or what ever needs delegate access to the File (UISegmentControl drove me nuts on this too), right click and drag a connection on “New Referencing outlet” to the Docks “Files Owner”, and a list will pop up.

Like wise, you can right click on the “Files Owner” and remove connections easily there, or make new ones.