1

I copied FairListViewController class to my project. I renamed it to ExibitorViewController.

There is an IBOutlet called

UITableView *fairListTableView;

in nib file. I change it with

UITableView *exibitorTableView;

Now every thing works fine. But one thing I notice that the previous tableView IBOutlet (which is fairListTableView here)" name still listed on the

ExibitorViewController.xib > File's Owner > Connection Inspector > OutLets section.

Though it was unconnected and don't bother at all. To erase it, I have to go to the nib xml file. I've done the following steps:

  1. right click on ExibitorViewController.xib
  2. File > Open As > Source Code
  3. search for the (Control+F) fairListTableView
  4. delete the related code from there.

The code I found is :

<string>fairListTableView</string>
   <object class="IBToOneOutletInfo">
      <string key="name">fairListTableView</string>
      <string key="candidateClassName">UITableView</string>
   </object>

But after saving and cleaning the project that IBOutlet still shows up there. If anyone knows the tricks to remove it, please share with me.

Bart
  • 17,070
  • 5
  • 61
  • 80
Tulon
  • 4,011
  • 6
  • 36
  • 56

3 Answers3

0

Have you tried removing it in Interface Builder, instead of changing the .xib XML? XCode most likely saves what's present in Interface Builder when quitting, so it may overwrite any changes you did manually.

user2599140
  • 476
  • 2
  • 9
  • Actually the change make happen systematically, but some how xcode hold the old IBOutlet in memory. I open it in an other MAC and suddenly explore the IBOutlet is gone!! Thanks for you comment. Stay well. :) – Tulon Jul 28 '13 at 16:10
0

Sometimes I have the same problem. Make sure you remove it from the Interface Builder, Product -> Clean and then restart Xcode.

That usually does the trick for me

Marcelo
  • 1,176
  • 1
  • 10
  • 29
  • yes, i did that every time after make the change (shift+command+k), but the old IBOutlet wasn't going. I tried that in my office MAC and now when i open the same code in my house MAC, it surprisingly doesn't exist!!! This time i don't have to do or clean any thing...It isn't there at all. :) By the way, next time i will not be panic in this kind situation. Thanks for commenting. Stay well. – Tulon Jul 28 '13 at 16:08
0

I found that I needed to delete the DerivedData folder for my project to get the "cached" IB references to be removed. Clean and restart was not working.

Using Swift and xCode 7.2. YMMV

Location ~/Library/Developer/Xcode/DerivedData/ More info about this is here.

Community
  • 1
  • 1
Cirec Beback
  • 693
  • 10
  • 16