View Single Post
Don't feel bad about needing help - OmniFocus' library is a little tricky to work with. (I can script Outliner just fine, but I had to ask an engineer for help with this.)

Something along these lines should work. You want to find the project, then tell it to add actions to itself. (Containing Project is read-only.)

Also, changed the date entry - the way they were before was actually a mathematical expression.

tell application "OmniFocus"
	tell default document
		set _context to context "Email" of context "Mac"
		tell project "Birthdays"
			set _startDate to date "Saturday, February 12, 2011 12:00:00 AM"
			set _dueDate to date "Wednesday, February 16, 2011 12:00:00 AM"
			set _repetition to {unit:year, steps:1}
			make new task with properties {name:"Birthday Test", start date:_startDate, due date:_dueDate, repetition:_repetition, context:_context}
		end tell
	end tell
end tell