{"id":19,"date":"2008-08-26T01:53:43","date_gmt":"2008-08-26T05:53:43","guid":{"rendered":"httpss:\/\/www.powenko.com\/blog\/?p=19"},"modified":"2008-08-26T01:53:43","modified_gmt":"2008-08-26T05:53:43","slug":"objective-c-tab-bar-crash-problem","status":"publish","type":"post","link":"https:\/\/www.powenko.com\/wordpress\/?p=19","title":{"rendered":"Objective-C Tab Bar crash problem,"},"content":{"rendered":"<p>Problem:<\/p>\n<p><strong>Tab Bar Application with UIWebView<\/strong><\/p>\n<hr style=\"color: #d1d1e1; background-color: #d1d1e1;\" size=\"1\" \/><!-- \/ icon and title --> <!-- message --><\/p>\n<div id=\"post_message_9423\">I have installed Beta 8 and I created a New Tab Bar Application but I am having issues in trying to make the UIWebView work.<\/p>\n<p>1. Create a New Tab Bar Application<br \/>\n2. Open up the SecondView.xib in IB, remove label and add a UIWebView<br \/>\n3. Select the File&#8217;s Owner Icon and add an Outlet called webView, with type UIWebView<br \/>\n4. Connect from the File&#8217;s Owner webView Outlet to the UIWebView control<br \/>\n5. Add to FirstViewController.h the IBOutlet UIWebView *webView;<br \/>\n6. Build and Go, select the Tab Bar called Second and I receive  __TERMINATING_DUE_TO_UNCAUGHT_EXCEPTION__<\/p>\n<p>If I go back and open the SecondView.xib file in IB and remove the webView Outlet connection to the UIWebView control, I can Build and Go and I select the Tab Barc called Second and the UIWebView shows up without error.<\/p>\n<p>At this point I cannot figure out what I am doing wrong in order to automatically open the UIWebView to a specific URL. (I know I did not add the code to open up the URL yet because of my error above).<\/p>\n<p>Thanks<\/p>\n<\/div>\n<p>Answer:<\/p>\n<p>1.Make new project with &#8220;Tab Bar Application&#8221; template.<br \/>\n2.Add &#8220;IBOutlet id label;&#8221; In @Interface of &#8220;FirstViewController.h&#8221;.<br \/>\n3.Link label and File&#8217;s Owner In &#8220;SecondView.xib&#8221;.<br \/>\n4.Build and run, then termination will occur when select second tab.<br \/>\n|<br \/>\n5.Open &#8220;MainWindow.xib&#8221; and select second tab.<br \/>\n6.Change Class of View Controller (Second)  to &#8220;FirstViewController&#8221;.<br \/>\n7.Build and run, then app will go well.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Problem: Tab Bar Application with UIWebView I have inst [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-19","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/www.powenko.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/19"}],"collection":[{"href":"https:\/\/www.powenko.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.powenko.com\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.powenko.com\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.powenko.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=19"}],"version-history":[{"count":0,"href":"https:\/\/www.powenko.com\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/19\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.powenko.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=19"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.powenko.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=19"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.powenko.com\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=19"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}