• 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: Catch click on dock icon ?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Catch click on dock icon ?


  • Subject: Re: Catch click on dock icon ?
  • From: Peter Bunn <email@hidden>
  • Date: Fri, 31 Aug 2007 22:37:25 -0500

Oops...

Save as a 'simple' application... _not_ a bundle...

Or as a bundle:

--

tell application "System Events"
		set visible of application process "applet" to false
		repeat until visible of application process "applet" is true
		end repeat
	end tell

--

Sorry.  Trying to be smart this late in the day is unbecoming for me.

Peter B.

-----

I wrote:

>I think the following can be adapted to suit your needs, and does not
>require a stay open app...
>
>Save this example as an app bundle named 'Wait'.
>
>Peter B.
>
>-----
>
>
>-- some of your script
>
>tell me to activate
>display dialog "Do it now...?" buttons {"Cancel", "Wait", "OK"} default
>button 3
>set button_pressed to button returned of result as text
>
>if button_pressed is "Wait" then
>	tell application "System Events"
>		set visible of application process "Wait" to false
>		repeat until visible of application process "Wait" is true
>		end repeat
>	end tell
>end if
>
>-- resume script on dock click
>
>tell me to activate
>display dialog "Are you sure you're ready...?" buttons {"Cancel", "OK"}
>default button 2
>
>-- rest of script
>
>-----
>
 _______________________________________________
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

  • Prev by Date: Re: Catch click on dock icon ?
  • Previous by thread: Re: Catch click on dock icon ?
  • Index(es):
    • Date
    • Thread