简体   繁体   中英

How to load a specific view property from an xib?

I have an xib file in which I have a view. I made a custom view of mine as its file owner in the interface builder.

I have a subview as an outlet for a view in the xib.

On creating the view object isn't loading the subview outlet from the xib.

Is specifying a file as the owner in the IB sufficient ? Or I will have to load the xib in initWithFrame of my View as well ?

On creating the view it will create all the subviews from the XIB. It is sufficient to specify the file owner in interface builder.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM