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

Getting list of unselected items Thread Tools Search this Thread Display Modes
I'm trying to modify the Snooze script to snooze unselected items rather than those that are selected. I'm new to Applescript, though, so I'm not sure the best way to proceed. Clearly the following line obtains the selected items:

set validSelectedItemsList to value of (selected trees where class of its value is not item and class of its value is not folder)

1. What are the possible classes of value attributes? What is the "item" class?
2. Assuming there is no object for unselected items, I'm guessing I would have to get the full list of items in the view and then remove the selected ones? Is there an easy way in applescript to find the relative complement of the selected items with respect to the total without two nested for loops?

tell application id "OFOC"
	tell sidebar of front document window of default document
		set lstProjects to value of descendant trees where selected = false and class of its value is not item and class of its value is not folder
	end tell
end tell
Filtering out objects which return a class of item just excludes non-data items like the Inbox and Library nodes in the sidebar tree, and various grouping labels in the content panel.

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Similar Threads
Thread Thread Starter Forum Replies Last Post
Getting list of unselected items sgoldstein OmniPlan Extras 0 2012-07-10 07:48 PM
Copy a list of items and make them separate items in OF? leo OmniFocus 1 for Mac 4 2011-03-06 09:46 AM
adding items to the top of the list calvinb OmniFocus for iPhone 1 2010-06-14 08:36 PM
Can't do operations on items selected in list view Leon Starr OmniGraffle General 1 2008-06-23 10:04 AM
List of items set by a perspective Frosty Crunch OmniFocus 1 for Mac 4 2008-01-28 02:50 PM

All times are GMT -8. The time now is 12:35 AM.

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