Re: How does an NSTextField know that it's value has changed?
Re: How does an NSTextField know that it's value has changed?
- Subject: Re: How does an NSTextField know that it's value has changed?
- From: Joanna Carter <email@hidden>
- Date: Tue, 13 Apr 2010 22:07:14 +0100
Hi Brian
> The problem seems to be that I'm changing the value of the textfield programatically, but some part isn't getting the message.
And this is your problem. If you change the value of a text field by typing into it, then that value is sent to the property on the model, but this is not true for programatic changes. The MVC pattern and bindings work when you change the value in the model programatically, not the text field. As long as the property in the model is KVO compliant, the text field will follow the changes to the property.
Joanna
--
Joanna Carter
Carter Consulting
_______________________________________________
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