• 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: How to determine the status of FMP tables in the Window menu
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to determine the status of FMP tables in the Window menu


  • Subject: Re: How to determine the status of FMP tables in the Window menu
  • From: Peter Gort via AppleScript-Users <email@hidden>
  • Date: Thu, 19 May 2022 08:46:04 +1000

Hi Marc,

The (brackets around the database name) means that database has been referenced
by another, and therefore is open, but has not instantiated a window.

Another way to find the list of databases that are in this state would be to
probe the menubar.  It does require that System Preferences -> Security &
Privacy -> Privacy -> Accessibility have an entry for FileMaker, or this won’t
work.

Note that this idea does not target FileMaker Pro at all, it targets the
“System Events” application.  Therefore this works even if the FileMaker
database user does not have permission to run AppleScripts.

activate application "FileMaker Pro 18 Advanced"
tell application "System Events"
        tell process "FileMaker Pro Advanced"
                tell menu 1 of menu item "Show Window" of menu 1 of menu bar
item "Window" of menu bar 1
                        get name of every menu item whose name begins with "("
                end tell
        end tell
end tell

Peter Gort

> On 19 May 2022, at 2:27 am, Jenni via AppleScript-Users
> <email@hidden> wrote:
>
>       Is there a way via AppleScript to tell if a FileMaker db is "hidden"?
> I don't mean a hidden window like when using the Hide Window command, but a
> hidden file - when it's listed in the Window menu surrounded by (parentheses).
>
>       Doing this:
>
> on is_db_open(db_name)
>       tell application "FileMaker Pro 18 Advanced"
>               if database db_name exists then
>                       return true
>               else
>                       return false
>               end if
>       end tell
> end is_db_open
>
> returns true either way.  I need a way to distinguish the status of the
> tables in the Window menu.

 _______________________________________________
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: 
 >How to determine the status of FMP tables in the Window menu (From: Jenni via AppleScript-Users <email@hidden>)

  • Prev by Date: Re: How to determine the status of FMP tables in the Window menu
  • Next by Date: Waiting for the disk to Eject
  • Previous by thread: How to determine the status of FMP tables in the Window menu
  • Next by thread: Re: How to determine the status of FMP tables in the Window menu
  • Index(es):
    • Date
    • Thread