Repeat a method, until right mouse button pressed

Hi,

I am looking for a Python solution to repeat a method until the user presses the right mouse button.

In detail, the method would pack the selected items in a specific list continuously including sub-objects and then by pressing the right mouse button, the script would go forward.

Is it possible?

Do you mean “pick the selected?” If so, when just use GetObject.GetMultiple. Or am I confused?

– Dale

No, This is what I would like to do.

I realised, that the different type of GetObject(s) python methods with different features.
For example GetObject supports to select sub-object but GetObjects does not. That’s why, what if I repeat the GetObject method and I can get an instant GetObject(s) method by repetition. I think it is smart :slight_smile: if it is possible.

Both GetObject.Get and GetObject.Get support selecting top-level or sub-level objects.

– Dale

When I double click on GetObject python method in the code editor from the method list it gives me the following:

rhinoscriptsyntax.GetObject ( message=None, filter=0, preselect=False, select=False, custom_filter=None, subobjects=False)

for GetObjects the parameters are slightly different;

rhinoscriptsyntax.GetObjects ( message=None, filter=0, group=True, preselect=False, select=False, objects=None, minimum_count=1, maximum_count=0, custom_filter=None )

And subobject is available in the GetObject. Do you mean GetObject.Get in RhinoCommon?

Yes.

The object getters in rhinoscriptsyntax were never designed to pick subobjects.

– Dale