Create cross section in mechanical via script

CD
Cedric Devivier
Mon, May 13, 2024 10:29 PM

Hi everyone,

I am trying to run a mechanical script in which I create a cross section. I can run this without issue in the scripting interface:

cs = ExtAPI.DataModel.Project.Model.CrossSections.AddCircularCrossSection()

But it fails if I run it as a script.

Would anyone have any idea on how to solve this?

Thanks,
Cédric


Cédric Devivier, PhD

Visiting Researcher

Hi everyone, I am trying to run a mechanical script in which I create a cross section. I can run this without issue in the scripting interface: cs = ExtAPI.DataModel.Project.Model.CrossSections.AddCircularCrossSection() But it fails if I run it as a script. Would anyone have any idea on how to solve this? Thanks, Cédric --------------------------------------------------- Cédric Devivier, PhD Visiting Researcher