• 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: UI scripting & iChat
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: UI scripting & iChat


  • Subject: Re: UI scripting & iChat
  • From: Bill Cheeseman <email@hidden>
  • Date: Wed, 14 Dec 2005 18:51:59 -0500
  • Thread-topic: UI scripting & iChat

on 2005-12-14 5:57 PM, Tom Bonura at email@hidden wrote:

> I can get the chat invitation window and even its elements but I cannot seem
> to get either the window to become activated by using "click" nor can I send a
> click to the button.
>
> tell application "System Events"
> tell process "iChat"
> get every window whose name is "Buffy" --  the name of the sender of the
> invite
> if the result is not {} then
> set theW to item 1 of the result
> tell application "iChat" to activate
> click theW  --  does not activate the window
> end if
> end tell
> end tell

A couple of suggestions:

1. Try moving the 'tell application "iChat" to activate' line to the top of
the script. It might not be necessary, but there are a surprising number of
situations where GUI Scripting doesn't work right if the application is not
frontmost.

2. Clicking a window is not the way to bring it to the front in GUI
Scripting. If the 'main' attribute of the window is settable, try 'set main
of theW to true'.

--

Bill Cheeseman - email@hidden
Quechee Software, Quechee, Vermont, USA
http://www.quecheesoftware.com

PreFab Software - http://www.prefab.com/scripting.html
The AppleScript Sourcebook - http://www.AppleScriptSourcebook.com
Vermont Recipes - http://www.stepwise.com/Articles/VermontRecipes


 _______________________________________________
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

References: 
 >UI scripting & iChat (From: Tom Bonura <email@hidden>)

  • Prev by Date: UI scripting & iChat
  • Next by Date: last day of the month of a date
  • Previous by thread: UI scripting & iChat
  • Next by thread: last day of the month of a date
  • Index(es):
    • Date
    • Thread