Cocoa Bindings, NSMatrix, setting programmatically
Cocoa Bindings, NSMatrix, setting programmatically
- Subject: Cocoa Bindings, NSMatrix, setting programmatically
- From: Renaud Boisjoly <email@hidden>
- Date: Tue, 27 Apr 2004 22:27:32 -0400
Hi all!
I have an NSMatric bound to an array of strings. The values of the
NSButtonCells are entered directly in Interface Builder.
Everything works, the Bindings keep the selection in the NSMatrix. My
issue is to set a value for the selection programmatically.
For example. My class is called "RBThings" which has a property called
"weekdays" (NSMutableArray) and the table which contains the weekday
names is bound to this using an NSArrayController. But I wish to set
the value in the weekdays of this object initially in its init method
(or elsewhere if there is a better way).
I have a feeling that what is stored for the binding is the actual
object (NSCell?) in the Matrix which is selected. What I collect in the
array seems to be the string though... but if I programmatically set
the value of the weekdays property to "Monday", the interface doesn't
reflect this.
What is the proper way to set the value of a bound property
programmatically?
I hope my description is clear enough...
thanks for any help!
- Renaud
_______________________________________________
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.