def DeleteAllClusters( oObj ): oObj = Application.Selection(0) for oCluster in oObj.activeprimitive.geometry.clusters: if Application.classname( oCluster ) == 'Cluster' and oCluster.type == 'poly': Application.DeleteObj(oCluster)