The idea of sending yourself an email and then letting Outlook process it on the desktop computer and create the relevant task is a simple one, although it does have the minor drawback of having to have the desktop computer and Outlook constantly running if you want your Tasks to be updated in real-time.
Anyway, I thought I would give it a try by using an Outlook rule to filter any emails that I send to myself with a specific in the subject line.
This rule invokes a VB Macro that I am pasting below... It basically creates a new Task everytime such an email arrives, and then DELETES THE EMAIL (remove the last line of code if you dont want to do this).
The code is also very klutzy... the macro will look for any strings in the email which match the hard-coded list of Actions and Projects in the code (search for **** to find this). It will then try to assign Categories, Actions and a Project to the Task that it creates.
HOWEVER, it doesnt really work, because I have not found out who to assign Actions and Projects to this task: if I try the obvious:
objTask.Action = ...
I get an error. I think the problem is that a regular Outlook Task doesnt have the Action property. So one has to create the same type of GTDTask that the GTD Outlook add-in uses.
Maybe someone with more programming skills knows how to do this?
Outlook VB Macro below
Sub SetCategories(MyMail As MailItem)
' This creates a new Task every time it processes an email whose Subject line starts with the string "stask ".
' The Categories of the Task are set by searching for any strings such as @Calls in the body of the task
' The subject, body, etc of the task are just copied from the email
' Things to do:
' Set the .Action of the Task
' allow the creation of Calendar events as well as tasks...
Dim sAction, sProject, sCategories As String
Dim sActions, sProjects As Variant
Dim i As Integer
Dim sBody, sSubject As String
Dim strID As String
Dim objNS As Outlook.NameSpace
Dim objMail As Outlook.MailItem
Dim objTasks As Outlook.MAPIFolder
Dim objTask As Outlook.TaskItem
strID = MyMail.EntryID
Set objNS = Application.GetNamespace("MAPI")
Set objTasks = objNS.GetDefaultFolder(olFolderTasks)
Set objMail = objNS.GetItemFromID(strID)
sBody = LCase(objMail.body)
sSubject = objMail.Subject
If Left(LCase(sSubject), 6) = "stask " Then
Set objTask = CreateItem(olTaskItem)
' Include all your actions here ****
sActions = Array("@Agendas", "@Anywhere", "@Calls", "@Computer", _
"@Errands", "@Waiting For", "@Read", "@Internet", _
"@Office", "@Deferred", "Projects", "Someday")
' Include all your Projects here
sProjects = Array("@GTD Setup", "@Boat", "@CompMaint")
i = 0
If sActions(i) <> "" Then If InStr(sBody, LCase(sActions(i))) > 0 Then sAction = sActions(i)
If sProjects(i) <> "" Then If InStr(sBody, LCase(sProjects(i))) > 0 Then sProject = Right(sProjects(i), Len(sProjects(i)) - 1)
i = i + 1
Loop Until i > UBound(sActions) Or i > UBound(sProjects)
If sProject <> "" Then
sCategories = sAction & ", " & sProject
sCategories = sAction
'objMail.categories = sCategories
' the below line doenst work for some reason...
'.Actions = sAction
.categories = sCategories
.Subject = Right(sSubject, Len(sSubject) - 6)
.StartDate = Now
.Status = olTaskInProgress
.Importance = objMail.Importance
.body = objMail.body