• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Help binding values to a tableview
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Help binding values to a tableview


  • Subject: Help binding values to a tableview
  • From: email@hidden
  • Date: Thu, 13 May 2004 05:09:45 -0500 (GMT-05:00)

Kinda long, but I am confused.

My problem is that I have 1 list of elements and each element has two lists to it. I want to have it so when I select one element from the first view, the two associated lists will display in the other two views. I almost got it to work one time but I don't know what I did and Xcode crashed while saving.

I have 3 tables in my main window and three different arrays of info. for now array1, 2, and 3. table 1, table 2, table 3. The arrays exist in mycontroller. I have an NSObject controller, (alias) and 3 NSArrayControllers.

So, in the nib file I have an instance of my controller, I set the outlet content of alias to my controller. Then I did the value binding in each array controller. Bound each table's value to its array controller. 1-1-1 etc . And I am almost done. I set my controller as the delegate of table1.

In my controller With the method selectionDidChange I tell the two other controllers to removeObjects:array2]; array3]; then I give the arrays new values directly. When I tried saying a2 controller addObject, it crashed. But it lets me say a2 addObject;

at this point there is nothing in the lists after a change, even though there was something displayed upon launch.

So then I try a1 controller addObjects: array1];

When I run the app though, it crashes about 2 seconds after I try to switch selection.

telling the controller to add objects just makes it crash And I am not sure how to get the controller to update correctly. Maybe I misunderstood somethings I was reading. If anyone could help me understand this better I would really appreciate it.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Prev by Date: Resizing NSImageView and its image
  • Next by Date: window rotation
  • Previous by thread: Resizing NSImageView and its image
  • Next by thread: Re: Help binding values to a tableview
  • Index(es):
    • Date
    • Thread