Running script error in ACT Stage page

Options
zggnph
zggnph Member Posts: 4
First Comment



I encountered the following error while running the script on the ACT Stage page.

Comments

  • Landon Mitchell Kanner
    Landon Mitchell Kanner Member, Employee Posts: 208
    First Answer First Comment 5 Likes First Anniversary
    Options

    Try importing the current SpaceClaim API by using the following code:

    import os, sys
    clr.AddReference("Ans.Utilities")
    from Ansys.Utilities import ApplicationConfiguration
    version = ApplicationConfiguration.DefaultConfiguration.VersionInfo.VersionString
    
    sys.path.append(os.environ["AWP_ROOT"+version]+"/scdm/Scripting")
    clr.AddReference("SpaceClaim.Api.V{}".format(version))
    clr.AddReference("SpaceClaim.Api.V{}.Scripting".format(version))
    exec('from LoadSCDMAPITypesV{} import *'.format(version))
    exec('from UtilitiesOnLoadV{} import *'.format(version))
    
  • zggnph
    zggnph Member Posts: 4
    First Comment
    Options

    Print the corresponding attributes using dir (SplitBody), without ByCutter.

  • Landon Mitchell Kanner
    Landon Mitchell Kanner Member, Employee Posts: 208
    First Answer First Comment 5 Likes First Anniversary
    Options

    See my previous comment: