Re: Mail Rule problem.
Re: Mail Rule problem.
- Subject: Re: Mail Rule problem.
- From: Brian Christmas <email@hidden>
- Date: Sun, 24 May 2015 14:03:40 +1000
G’day, and thanks S.J. and Axel.
I’m now saving the time variable in the user preferences folder as a .txt file.
Works well.
Regards
Santa
On 23 May 2015, at 10:35 pm, S. J. Cunningham <email@hidden> wrote:
On May 23, 2015, at 2:08 AM, Brian Christmas wrote:
>
> G’day scripters
>
> I’ve got a small script called from a Mail Rule every time a new message arrives, that announces the arrival, and calls the main email processing application.
>
> When several sequential messages arrive, the script runs multiple times, resulting in ‘echoes’.
>
> I’ve add a condition using a time storing property that only allows the script to run every 10 seconds, and it works fine when run as a script or application, but the Mail Rule somehow treats it differently, and the echoes are persisting.
>
> Anyone know of a way or getting the Mail Rule to treat the script normally, thus restricting the speech to every 10 seconds, please?
>
> Regards
>
> Santa
You are probably running into the problem that Applescript properties are not saved when running a Mail Rule. We discussed this a while back in the thread: "Properties not saved when a script is executed by a Mail rule?". The solution is to store the property in a file and read/write it every time the script runs. Kind of kludgy but what about Applescript isn't?
S. J. Cunningham
_______________________________________________
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