Re: Mail.app script help needed
Re: Mail.app script help needed
- Subject: Re: Mail.app script help needed
- From: deivy petrescu <email@hidden>
- Date: Fri, 18 Mar 2005 10:22:43 -0500
On Mar 18, 2005, at 2:55, Michelle Steiner wrote:
Here is the script:
tell application "Mail"
set account_List to (name of accounts)
end tell
set selected_Accounts to (choose from list (account_List) with
multiple selections allowed without empty selection allowed)
if selected_Accounts is not false then
tell application "Mail"
set include when getting new mail of every account to false
repeat with this_account in selected_Accounts
set (include when getting new mail of account this_account) to true
end repeat
end tell
end if
This line errors:
set (include when getting new mail of account this_account) to true
Here is the error:
set include when getting new mail of account "email@hidden"
to true
"Mail got an error: NSReceiverEvaluationScriptError: 4"
The "every account" line works, but the line that sets only one
account fails.
Michelle change your script to :
----
tell application "Mail"
set account_List to (name of accounts)
set selected_Accounts to (choose from list (account_List) with
multiple selections allowed without empty selection allowed)
if selected_Accounts is not false then
set include when getting new mail of every account to false
repeat with this_account in selected_Accounts
set this_account to contents of this_account --> major change
set (account this_account)'s include when getting new mail to true
end repeat
end if
end tell
---
deivy
--------------------------------------------
Agora quem da bola é o Santos,
Salve o novo campeão!
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden