I saw this example of how to select objects by name with a script, I would like to know if anyone knows how to modify it to be able to select all the objects with the subdivision surface modifier.
Thank you very much
# Deselect all objects
bpy.ops.object.select_all(action='DESELECT')
for o in bpy.data.objects:
# Check for given object names
if o.name in ("Cube.026","Cube.027","Cube.028"):
o.select_set(True)