I have an applescript which extracts the name, associated process and and other information about a target window. As of now, the script selects the target window via a "choose from list" dialog that contains all open windows from all processes. It would be much better if I could select the target window by highlighting it in the Finder. For example, this can be done for files and folders:
tell application "Finder" to set this_file to the selection
Question: Is there an equivalent method to do select windows from the Finder (using Applescript or Automator)?