Using the Worksheet window with ACT Extension

BenjaminStarling
BenjaminStarling Member Posts: 3
First Comment
**

In Mechanical, when the Geometry tree item is selected the worksheet window displays information about the properties of children objects. Similar behaviour exists for other tree objects such as Coordinate Systems and Analysis Settings.

How can I acheive similar behaviour for my ACT extension? When selecting the parent object, then the Home -> Worksheet button, I would like to show details of the children objects properties. The Worksheet window is available, but I am not sure if I can add data to it.

Answers

  • James Derrick
    James Derrick Administrator, Employee Posts: 275
    Ancient Membership 100 Comments 100 Likes 25 Answers
    admin

    Hi @BenjaminStarling thanks for the question! I'm pinging @AKD-Scripting-Team who will hopefully be able to help.

  • Ayush Kumar
    Ayush Kumar Member, Moderator, Employee Posts: 457
    100 Answers 250 Likes 100 Comments Second Anniversary
    ✭✭✭✭

    @BenjaminStarling not sure if setting worksheet data is exposed via Scripting APIs.

    @mohamed-koubaa, @Mike.Thompson any ideas?

  • Mike.Thompson
    Mike.Thompson Member, Employee Posts: 347
    25 Answers 100 Comments Second Anniversary 25 Likes
    ✭✭✭✭

    @BenjaminStarling @Ayush Kumar ,
    Attached is an example of something like this. There is not off-the-shelf access to a worksheet panel, but there are solutions available to make your own and attach it to a mechanical UI panel.

    There is an example mech project (.zip format) and also a scripted extension. Look at the NamedValuesManagerObj.py file and the onshow callback in the class object specified in the .xml. Follow the code towards making your own listview control and attaching it to a mechanical panel for UI interactions.

    Not this extension is not a functional app and has lots of other code. Don't use it for anything other than an example of this kind of action.