开发者

iPhone UIWebView weird build problem

开发者 https://www.devze.com 2022-12-18 17:48 出处:网络
This is strange.I have a custom Nib with a webView, all outlets are set properly.On the first \"Build and Run\", whenever I invoke the nib, it\'s just a blank white screen with my iPhone status bar at

This is strange. I have a custom Nib with a webView, all outlets are set properly. On the first "Build and Run", whenever I invoke the nib, it's just a blank white screen with my iPhone status bar at the top. Then, if I click Stop, and Build and Go again (without making any code changes) and I invoke the nib, I get my Nib开发者_如何学Go from Interface Builder exactly the way it should be, operating just fine.

This lasts and works until I make any changes in the custom view controller. If I make a change and want to test, I have to Build and Go, Stop, and Build and Go again to get my nib to display properly.

Has anyone ever experienced this? My ViewController is displayed modally.

Keep in mind that I don't make any code changes at all between Build and Go attempts.


The answer to this problem is that there are 2 nibs with the same name in the bundle. I am not sure how this happened, but I decided to check my connections (again) and when I opened the nib, it was empty. "That's odd." I thought to myself. I went to double click it again and wondered why it was at the bottom of my "Classes folder." Lo and behold, I had an extra one inside my project, as well as the original in the resources.

Just an FYI! I guess you can have two of the same file in the bundle...

0

精彩评论

暂无评论...
验证码 换一张
取 消