September 22, 200421 yr Here's my AppleScript (embedded into the FileMaker file as a calculation field: tell application "Finder" activate if not (exists disk "Engineering") then beep display dialog "You must first mount the Engineering volume." with icon 2 buttons ("OK") default button 1 else if file "050-0000-0108-00D.pdf" of folder "050-0000-01XX-XX" of folder "050-0000-XXXX-XX" of folder "050-XXXX-XXXX-XX" of disk "Engineering" exists then select file "050-0000-0108-00D.pdf" of folder "050-0000-01XX-XX" of folder "050-0000-XXXX-XX" of folder "050-XXXX-XXXX-XX" of disk "Engineering" open selection else beep display dialog "There is no PDF for this file." with icon 1 buttons ("OK") default button 1 end if end if end tell My problem is that when the script is activated and the PDF file is opened via the Finder, the FileMaker window still appears as if it is the front-most (active) window. That is, the window's title bar does not gray out like normal. What is the AppleScript command (if any) that "deactivates" the current application?
Create an account or sign in to comment