The Omni Group
These forums are now read-only. Please visit our new forums to participate in discussion. A new account will be required to post in the new forums. For more info on the switch, see this post. Thank you!

Go Back   The Omni Group Forums > OmniFocus > OmniFocus Extras
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
How do I move a project to a specific folder? Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
I am trying to figure out how to move a project from the bottom of the projects list to a specified folder. I am starting by figuring out how to duplicate a selected project to another location. I have:

Code:
tell application "OmniFocus"
	tell front document
		tell document window 1
			set theSelectedItems to selected trees of sidebar
			set theA to {tree 2 of tree 2 of sidebar of document window id 128 of document id "fqCMFexKSD8" of application "OmniFocus"}
			set theX to (value of item 1 of theSelectedItems)
			set theY to folder of theX
			set theZ to section of theY
			duplicate (value of item 1 of theSelectedItems) to after theA
		end tell
	end tell
end tell
I get:
  • "OmniFocus got an error: Canít make {tree 2 of tree 2 of sidebar of document window id 128 of document id "fqCMFexKSD8"} into type specifier," when when I try to duplicate the project to after theA.
  • "OmniFocus got an error: Attempted to move data objects to a nil container," when I try to duplicate the project to after theX and theY.
  • "OmniFocus got an error: Canít make {project id "oxQPHIP8MtA" of document id "fqCMFexKSD8", etc.} into type specifier," when I try to duplicate the project to after theZ.

How do I write a command that will move the selected project to a specified location?

Thanks,
Rebecca
 
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
can't move pre-existing project in to pre-existing folder kbs1138 OmniFocus 1 for Mac 3 2011-06-16 10:22 AM
script to make an inactive project active and move it to a selected folder kingsinger OmniFocus Extras 2 2010-11-15 08:52 PM
How to move project into folder? [A: Tap Edit, tap item, tap "move" button in Tbar.] Avis OmniFocus for iPhone 4 2010-07-07 10:27 AM
Feature Request: Move project from folder to folder jbarr OmniFocus for iPhone 2 2008-07-17 11:10 AM
Please move datafile to Documents folder jasong OmniFocus 1 for Mac 18 2007-11-20 09:51 AM


All times are GMT -8. The time now is 10:49 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2023, vBulletin Solutions, Inc.