AppleScript Priorité d'un e-mail

ryan_cheppers Messages postés 45 Statut Membre -  
ryan_cheppers Messages postés 45 Statut Membre -
Bonjour,

J'aimerais créer un script en AppleScript en fonction de la priorité d'un e-mail reçu sur Mail.app.

Quelle est la commande qu'il faut utiliser ? (if the priority of the mail is "high" then ne marche pas)

Merci d'avance.
A voir également:

1 réponse

ryan_cheppers Messages postés 45 Statut Membre 4
 
J'ai trouvé moi-même:

repeat with mail in theMessages
try
set priHeader to the header "X-Priority" of the mail
set priHeaderStr to the content of priHeader as string
if priHeaderStr contains "1" then
...
end if

on error
return "error"
end try

end repeat
0