Re: text field question
Re: text field question
- Subject: Re: text field question
- From: Kyle Sluder <email@hidden>
- Date: Thu, 23 Feb 2012 08:09:25 -0800
On Feb 22, 2012, at 4:59 PM, "Rick C." <email@hidden> wrote:
> Hi,
>
> I have a panel with a number of text fields where a user should enter numeric values. These text fields are setup with Sent on End Editing so that if the user presses enter or tabs or changes text fields the value will be entered. The problem is sometimes a user just types in a value and that's it...no enter, no tab, no changing text fields and the value is never received. How does everyone else handle this and what can you recommend?
This is a FAQ, though the specifics of the answer are situation-dependent.
The gist is: send [panel makeFirstResponder:panel] at the appropriate time. Or it you're using bindings, send -commitEditing. The "appropriate time" in the case of a persistent panel is probably when it's about to lose key window status.
If your users want to see the results of their input without having to dismiss or leave the panel, they will understand having to press Return to commit editing.
--Kyle Sluder
_______________________________________________
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