How do I fetch Selection Information Data in Mechanical?
You can use the following snippet to export data to a Text file and then parse it to load data in your Python session.
cmd = '''DS.Script.exportDataToFileSelectionInfoPane("D:\\\\test.txt");''' ExtAPI.Application.ScriptByName("jscript").ExecuteCommand(cmd)
Note that you may need to first ensure that the Selection Information panel is visible: https://discuss.ansys.com/discussion/4534/open-the-selection-information-panel-in-mechanical/p1?new=1