View Single Post
Ah you are correct. Sorry.

But you can set a Mail Rule to work on "every message" and then run the following AppleScript, which will add every flagged message to the inbox.

Quote:
-- Sloppily patched together by Lucas to import flagged messages.

(* Derived by dbyler from "Jott to OmniFocus" to work with reQall mail. See below. *)

-- Derived from work that is Copyright © 2007, Curtis Clifton All rights reserved.
-- Modified to work specifically with Jott messages.

-- If true, then the sender of the message is included in the action's description.

-- From http://forums.omnigroup.com/showthread.php?t=7651

property includeSender : false

property messageSender : "reQall"

using terms from application "Mail"
on perform mail action with messages theMessages
try
set theMessageCount to count of theMessages
repeat with theMessageIndex from 1 to theMessageCount
if (flagged status of item theMessageIndex of theMessages) then
my process_message(item theMessageIndex of theMessages)
end if
end repeat
on error m number n
tell application "OmniFocus"
log "Exception in Mail action: (" & n & ") " & m
end tell
end try
end perform mail action with messages
end using terms from


on process_message(theMessage)
tell application "Mail"
set theContent to content of theMessage
set theDate to date sent of theMessage
set messageId to message id of theMessage
set theSubject to subject of theMessage
end tell

tell application "OmniFocus"
-- set messageStart to (offset of "added to reQall" in theContent) + 21
-- set messageEnd to (offset of "Invite your friends" in theContent) - 76
-- set taskName to strings messageStart through messageEnd of theContent
set taskName to theSubject
if (includeSender) then
set taskName to taskName & "—" & messageSender
end if
set theDoc to default document
tell theDoc
set propRecord to {name:taskName}
set theTask to make new inbox task with properties propRecord
end tell
tell theTask
set start date to theDate
set note to return & return & theContent
tell note
set theURL to "message://<" & messageId & ">"
set linkText to "Original Message"
insert linkText at before first character
set value of attribute "link" of style of paragraph 1 to theURL
end tell
end tell
end tell
end process_message