• 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: secure text fields
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: secure text fields


  • Subject: Re: secure text fields
  • From: Dave Balderstone <email@hidden>
  • Date: Wed, 20 Oct 2004 15:08:00 -0600


On Oct 20, 2004, at 2:12 PM, Martha Espinosa wrote:

Can I make this text field to only accept 8 characters?


there's probably a better way, but here's code I used in a Studio App to do something similar. It triggers when a button is clicked (in an "on clicked theObject" handler)

tell window of theObject
set theText to contents of text field "TextField"
if (count of characters of theText) is less than 8 or (count of characters of theText) is greater than 8 then display dialog "Enter exactly characters." buttons {"Okay"} default button 1
return
end if
end tell



djb

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


  • Follow-Ups:
    • Re: secure text fields
      • From: Michelle Steiner <email@hidden>
References: 
 >secure text fields (From: Martha Espinosa <email@hidden>)
 >Re: secure text fields (From: Martha Espinosa <email@hidden>)
 >Re: secure text fields (From: Martha Espinosa <email@hidden>)

  • Prev by Date: Re: secure text fields
  • Next by Date: Network Setup Scripting
  • Previous by thread: Re: secure text fields
  • Next by thread: Re: secure text fields
  • Index(es):
    • Date
    • Thread