How do I prompt the user to select groups

I can’t figure out how to create a dialog for selecting groups in rhino. I would like something along the lines of:

GetObject getter = new GetObject();
getter.GeometryFilter = ObjectType.Group;

If this is not possible, It would also suffice to have a way to query for what group (if any) a brep is in.

Thanks in advance :slight_smile:

https://developer.rhino3d.com/api/rhinocommon/rhino.input.custom.getobject/groupselect

I have tried setting this field to true and nothing changed, I’m not sure how this helps?

Try something like this:

GetObject go = new GetObject();
go.SetCommandPrompt("Select surfaces and polysurfaces");
go.GeometryFilter = ObjectType.Surface | ObjectType.PolysrfFilter;
go.GroupSelect = true;
go.GetMultiple(1, 0);

– Dale

1 Like

Ahhhhh, I see, it filters out objects in the group that are of a different type than the filter. That’s what I was missing. Thanks Dale!