iphone - Identify the current Navigation Bar -


i'm trying identify navigation bar in current view can add subview it.

i have seen code able identify navigation bar has been dynamically created , tagged:

uinavigationbar *thenavigationbar = (uinavigationbar *)[inparent.view viewwithtag:knavigationbartag]; 

but in case navigation bar not being created dynamically, it's not tagged. there way identify otherwise?

self.navigationcontroller.navigationbar 

only valid when called method in uiviewcontroller, of course. otherwise, try retrieve reference view controller , take there.


Comments

Popular posts from this blog

how to build hyperlink for query string in php -

php - What is the difference between $_SERVER['PATH_INFO'] and $_SERVER['ORIG_PATH_INFO']? -

queue - mq_receive: message too long -