View Single Post
Tho the shell is arguably cleaner and easier to follow than Applescript string handling:

property pstrSample : "This is the SECOND title,
and here is the SECOND note,
possibly continuing over various lines

on run
end run

on MakeTask2(strText)
	set str to quoted form of strText
	set strTask to do shell script "echo " & str & " | head -n 1"
	set strNote to do shell script "echo " & str & " | tail -n +2"
	tell application id "OFOC"
		tell default document to make new inbox task with properties {name:strTask, note:strNote}
	end tell
end MakeTask2