Skip to main content
Created a need for the ob variable.
Source Link
Leander
  • 27.8k
  • 2
  • 46
  • 109
import bpy,bmesh

ob   = bpy.data.objects['Cube']
mesh=bmeshmesh = bmesh.from_edit_mesh(bpy.context.objectob.data)
for v in mesh.verts:
    v.select = True

# trigger viewport update
bpy.context.scene.objects.active = bpy.context.scene.objects.active

Docs

import bpy,bmesh

ob = bpy.data.objects['Cube']
mesh=bmesh.from_edit_mesh(bpy.context.object.data)
for v in mesh.verts:
    v.select = True

# trigger viewport update
bpy.context.scene.objects.active = bpy.context.scene.objects.active

Docs

import bpy,bmesh

ob   = bpy.data.objects['Cube']
mesh = bmesh.from_edit_mesh(ob.data)
for v in mesh.verts:
    v.select = True

# trigger viewport update
bpy.context.scene.objects.active = bpy.context.scene.objects.active

Docs

Source Link
stacker
  • 38.9k
  • 31
  • 144
  • 245

import bpy,bmesh

ob = bpy.data.objects['Cube']
mesh=bmesh.from_edit_mesh(bpy.context.object.data)
for v in mesh.verts:
    v.select = True

# trigger viewport update
bpy.context.scene.objects.active = bpy.context.scene.objects.active

Docs