Re: Bindings array count to a label ( was Re: KVC beginners question )
Re: Bindings array count to a label ( was Re: KVC beginners question )
- Subject: Re: Bindings array count to a label ( was Re: KVC beginners question )
- From: Keary Suska <email@hidden>
- Date: Sun, 10 Aug 2008 11:32:36 -0600
- Thread-topic: Bindings array count to a label ( was Re: KVC beginners question )
8/10/08 10:52 AM, also sprach email@hidden:
> I did see the array operators ... and in IB ... i have the label set
> up to BIND ValueWithPattern ... bound to the controller, keypath
> "browserData.@count".
>
> I'm sure i'm just missing something VERY obvious/simple. sigh.
We need more info then. What is not working? Do you get an exception? Do you
always get a count of 0? Do you get a count, but it never changes? All of
these issues can have different causes.
> On Aug 10, 2008, at Sun-08 /10 /08-12:37 PM, Keary Suska wrote:
>
>> 8/10/08 10:09 AM, also sprach email@hidden:
>>
>>> I am attempting to understand KVC and am having a bit of trouble
>>> understanding some of the examples, as well as the documentation.
>>>
>>> What i'd like to be able to do is have a label in a window
>>> automagically updated with the current count of an array. I've tried
>>> several things in IB and in code but do not actually get the "count"
>>> of the items in the array.
>>>
>>> in the controller, the array is called "browserData" and basically
>>> drives a coverflow view and an IKBrowserView. the label is to show
>>> how
>>> many objects are in the array.
>>>
>>> I very much see the value in KVC/O and am wanting to make this a part
>>> of my basic coding practices but for some reason ( maybe lack of
>>> coffee/caffeine at this point) is preventing me from actually
>>> grasping
>>> it.
>>
>> You need an array operator:
>> http://developer.apple.com/documentation/Cocoa/Conceptual/KeyValueCoding/Con
>> cepts/ArrayOperators.html#//apple_ref/doc/uid/20002176-184206
Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden