views:

65

answers:

1

Does anyone show how to set the delegate properly for this without interface builder?

http://www.gauravv.com/2009/12/29/iphone-development-tip-custom-uinavigationbar/

+1  A: 

Since, it inherits from UINavigationBar it will contain all of the same @property's. Thus you can do self.delegate = delegateObject and it will set the delegate of the nav bar.

If you are defining it in the owner class you would do the following:

navbar.delegate = delegateObject;
rickharrison
thx, i inverse it which worked for me, self.navigationController.delegate = navBar;
Frank
Great, please accept my answer if it worked. Thanks!
rickharrison