new todo with url reference
new todo with url reference
- Subject: new todo with url reference
- From: James Roberts <email@hidden>
- Date: Tue, 05 Feb 2013 04:29:55 -0500
I have a script that creates a new todo based on a Mail rule. For sometime now (ML ?) it has periodically failed to set the URL pointing back to the original msg. I finally sat down and figured out the problem. If a msg id contains % calendar refuses to set the url.
message id "510C483C.1080407@ name.com” works fine
if I escape the % in the id I get a “expecting “” found %” error. If I parse out the % the url sets but of course does not point to a real msg. If I drag the msg into the todo in BusyCal (not scriptable) the url is set and the added % don’t seem to cause any problems. Does anyone know a way that I can format msgURL so Calendar will just set the url and not worry about the content?
on createTodo(todoMsg, msgId) set theDueDate to (current date) + 5 * days set msgUrl to ("message:<" & msgId & ">") tell application "Calendar" tell calendar id "7F1A8DB2-DC7B-4AF2-BAE6-C003E14ECF8F" make new todo at end with properties {summary:todoMsg, due date:theDueDate, priority:high priority, url:msgUrl} end tell end tell end createTodo
James Roberts
"Nothing travels faster than the speed of light, with the possible exception of bad news, which obeys its own set of laws" ~ Douglas Adams
|
_______________________________________________
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