• 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: Calling methods on other applications?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Calling methods on other applications?


  • Subject: Re: Calling methods on other applications?
  • From: Ken Tozier <email@hidden>
  • Date: Sun, 3 Apr 2005 06:45:16 -0400

I played around with AppleScript a little and this script will get you a list of all open documents for applications that respond to the "documents" command. Resizing them will be a trickier as each app seems to define width and height their own way and some apps don't allow resizing. It might be a wash.

set docList to GetDocumentList()

on GetDocumentList()
set resultList to {}
tell application "Finder"
set appList to name of application processes
end tell


repeat with anApp in appList
try
tell application anApp
set docList to documents
set resultList to resultList & docList
end tell
end try
end repeat
return resultList
end GetDocumentList

Enjoy,

Ken
 _______________________________________________
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: 
 >Calling methods on other applications? (From: Benjamin Blonder <email@hidden>)
 >Re: Calling methods on other applications? (From: Finlay Dobbie <email@hidden>)
 >Re: Calling methods on other applications? (From: Conrad Carlen <email@hidden>)
 >Re: Calling methods on other applications? (From: Ken Tozier <email@hidden>)
 >Re: Calling methods on other applications? (From: "Mike Hall" <email@hidden>)

  • Prev by Date: Re: Calling methods on other applications?
  • Next by Date: calling 'KeyScript' from Cocoa-Java project
  • Previous by thread: Re: Calling methods on other applications?
  • Next by thread: Re: Calling methods on other applications?
  • Index(es):
    • Date
    • Thread