• 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: Scripting the Notes app
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scripting the Notes app


  • Subject: Re: Scripting the Notes app
  • From: 2551phil <email@hidden>
  • Date: Wed, 29 Jun 2016 23:22:46 +0700


On 29 Jun 2016, at 21:10, 2551phil <email@hidden> wrote:

Sub question: how can I get System Events to reliably send a textfield’s action?


Frankly, I should have known the answer was ‘delay 1’…


set searchString to "something that will return  a hit"
tell application "Notes" to launch
tell application "System Events"
tell application process "Notes"
set its frontmost to true
set aButton to its text field 1 of UI element 10 of toolbar 1 of item 1 of window 1
tell aButton
set its focused to true
delay 1 # this old chestnut again... :(
set its value to searchString
action "AXConfirm"


end tell
end tell
end tell


Bill answered my 3rd question; I’ve answered my 2nd question.
Anyone up for Q1 and Q4?





phil


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

References: 
 >Re: path to script file in script's folder (From: Mitchell L Model <email@hidden>)
 >Re: path to script file in script's folder (From: Shane Stanley <email@hidden>)
 >Scripting the Notes app (From: 2551phil <email@hidden>)

  • Prev by Date: how to get sender and time in response to list message?
  • Next by Date: Re: AppleScript-Users Digest, Vol 13, Issue 279
  • Previous by thread: Re: Scripting the Notes app
  • Next by thread: type string vs. text
  • Index(es):
    • Date
    • Thread