On May 1, 2012, at 14:23 , Ben Kennedy wrote: > I have an NSTableView whose data source is bound to an NSArrayController. To > one of its columns (displaying a custom type) I have attached a custom > NSFormatter subclass. The NSFormatter correctly returns NO from > getObjectValue:forString:error: if the supplied string is not acceptable. > Despite this, however, validation is not enforced; when tabbing out of the > field, the table view carries on and just assigns a null value to the > corresponding property.
Double-check that "Validates immediately" is checked for the binding. Counter-intuitively, this doesn't mean "immediately" in the sense of every keystroke, but "immediately" in the sense of when editing ends. If it's not checked, validation is presumably deferred until an entire view's worth of fields has been entered. _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com