View Single Post
Not of much consequence with only a few items selected, but it is generally a good idea to cache references, and avoid repeatedly fetching the same data across object interfaces.

i.e. you can save a little ink and run-time with something like:

Code:
tell application id "com.omnigroup.OmniFocus"
	
	set lstTree to selected tree of content of front window
	set dteTarget to current date
	
	if length of lstTree > 0 then
		
		repeat with oItem in lstTree
			set oTask to value of oItem
			set start date of oTask to dteTarget
		end repeat
		
	end if
	
end tell
--

Last edited by RobTrew; 2009-12-07 at 08:25 AM..