How to generate mesh on selected body with and without looping?
Chemsdine CHEMAI
Member, Employee Posts: 201
✭✭✭✭
Best Answer
-
While looping one can use the following code :
currentIds = ExtAPI.SelectionManager.CurrentSelection.Ids for id in currentIds : geoBody = ExtAPI.DataModel.GeoData.GeoEntityById(id) treeBody = ExtAPI.DataModel.Project.Model.Geometry.GetBody(geoBody) treeBody.GenerateMesh()
and without looping (after activating all tree objects) :
cmd="""DS.Script.doModelPreviewMesh();""" ds=ExtAPI.Application.ScriptByName("jscript").ExecuteCommand(cmd)
0
Answers
-
Hi @Chemsdine CHEMAI . It seems this method is no longer available at 24.2:
DS.Script.doModelPreviewMesh();Any JS method at 24.2?
0