Notifications
Clear all

[Closed] How can I check the existance of SelectionSets?

I need to put a routine to check the existance of a SelectionSet and delete the SelectionSet.

For example…

If there is a SelectionSet “temp” in my scene, I want to delete the SelectionSets and proceed to other command.

Thanks in advance

1 Reply

Try this function:

fn deleteSelectionSet selSetName = (
	if selectionSets[selSetName] != undefined do (
		deleteItem selectionSets selSetName
		return true
	)
	return false
)

Keep in mind this function deletes the selection set but not the nodes contained by the set.

Greets.