• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Limiting Character Input In An NSTextField
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Limiting Character Input In An NSTextField


  • Subject: Re: Limiting Character Input In An NSTextField
  • From: Ondra Cada <email@hidden>
  • Date: Wed, 27 Apr 2005 00:06:06 +0200

Ian,

On 26.4.2005, at 23:59, Ian was here wrote:

Does anyone know how to limit the number of characters
that can be entered into an NSTextField. I have a
unique situation where only five numbers should be
entered, and each number should only be a value from 1
to 5.

See "NSFormatter".

I tried subclassing NSTextField and using
KeyDown() to catch each number entered, but the
KeyDown() method never gets called?!?!

That's since NSTextField never edits anything -- see "field editor". --- Ondra Čada OCSoftware: email@hidden http://www.ocs.cz private email@hidden http://www.ocs.cz/oc

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Limiting Character Input In An NSTextField (From: Ian was here <email@hidden>)

  • Prev by Date: Re: Trouble drawing a polygon...
  • Next by Date: Re: ADC Select Membership
  • Previous by thread: Limiting Character Input In An NSTextField
  • Next by thread: "VMWare" for the Mac - running OSX on OSX
  • Index(es):
    • Date
    • Thread