Jump to content
Server Maintenance This Week. ×

getting an applescript that includes FM to work with Mail rules


This topic is 4974 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I am trying to debug an applescript that I would like to work automatically with Mail rules. I have a manual version of the script that works perfectly. So would anyone know why in the following script

tell application "FileMaker Pro Advanced"

	activate

	say "FileMaker opened"

	if exists database ¬

		"•_reservations_Petit_Globe" then

		

		say "file opened"

		show database "•_reservations_Petit_Globe"

	else

		

		getURL "FMP7://[email protected]/•_reservations_Petit_Globe"

		

		delay 10

		say "file opened"

	end if

	

	show layout "import"

	

	say "layout opened"

	

	try

		delete every record

	end try

	

	say "deleted"

end tell

this works perfectly when summoned manually but if it is a Mail rule it will only bring the file to the front if it is already opened, but will not open it if it is closed.

This is only part of a larger script but it where it gets stuck for the moment. The "say" lines are just to help me debug it.

Link to comment
Share on other sites

This topic is 4974 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.