How to add table in custom load and custome result ?

Options
1990chs
1990chs Member Posts: 44
First Comment Name Dropper

I want to define a custome load and custome result ACT extension. Then I need to define some load values using table data, although workbench provide "Worksheet.PropertyGroupEditor.PGEditor", but it is not good to use.

Custom Load Example
The following picture is a self define custome load. I want to define a load values table in Table area.

Custom Result Example
The following picture is a self define custome result. I want to define a table to add material yield stresses with different temperatures.

So, is any way to define custom table in Table panel ?

Answers

  • Pernelle Marone-Hitz
    Pernelle Marone-Hitz Member, Moderator, Employee Posts: 831
    First Comment First Anniversary Ansys Employee Solution Developer Community of Practice Member
    Options

    I'm afraid the only solution is indeed to use a and define tabular data through the Worksheet.PropertyGroupEditor.PGEditor class.

  • 1990chs
    1990chs Member Posts: 44
    First Comment Name Dropper
    Options

    @Pernelle Marone-Hitz said:
    I'm afraid the only solution is indeed to use a and define tabular data through the Worksheet.PropertyGroupEditor.PGEditor class.

    It is very sad to hear that, I am not sure weather it is work if I use Ansys.UI.Toolkit.GridView to create a table and add to Table Panel.
    Maybe I can try someday in the future.

  • Mike.Thompson
    Mike.Thompson Member, Employee Posts: 316
    First Answer First Anniversary First Comment 5 Likes
    Options

    You should be able to use the Ansys.UI.Toolkit.GridView control to make a table. You can also then attach that control to the tabular data window. This has a slightly different look/feel than the Mechanical native tabular data control, and you will need to program the interface from the ground up.

    You can also use any other UI options like windows forms as a pop up window. This is good for compatibility, but you cannot embed the controls into the mechanical pane at this time.

    FYI... Take a look at the bolt tools add on. It has some utilization of this control and also a ready-made module for attaching controls to the mechanical interface (AttachControlToMechanical.py)

  • 1990chs
    1990chs Member Posts: 44
    First Comment Name Dropper
    edited March 19
    Options

    @Mike.Thompson said:
    You should be able to use the Ansys.UI.Toolkit.GridView control to make a table. You can also then attach that control to the tabular data window. This has a slightly different look/feel than the Mechanical native tabular data control, and you will need to program the interface from the ground up.

    You can also use any other UI options like windows forms as a pop up window. This is good for compatibility, but you cannot embed the controls into the mechanical pane at this time.

    FYI... Take a look at the bolt tools add on. It has some utilization of this control and also a ready-made module for attaching controls to the mechanical interface (AttachControlToMechanical.py)

    Yes, I have ever read the controls to the mechanical interface and know how to add to Table panel (DefaultPanelEnum=Ansys.ACT.Interfaces.Mechanical.MechanicalPanelEnum.TabularData). But I am not sure weather the Gridview object can bonded to xml file in order to get the Gridview object in some callbacks?

  • Mike.Thompson
    Mike.Thompson Member, Employee Posts: 316
    First Answer First Anniversary First Comment 5 Likes
    Options

    You can create and attach the control with the OnShow object callback per the xml file. You then detach it with the OnHide callback (also in xml).
    For using the control, the UI control has its own callbacks like text changed, cell activated etc…these are specified in python and not in the xml.
    I hope this helps

  • 1990chs
    1990chs Member Posts: 44
    First Comment Name Dropper
    Options

    @Mike.Thompson said:
    You can create and attach the control with the OnShow object callback per the xml file. You then detach it with the OnHide callback (also in xml).
    For using the control, the UI control has its own callbacks like text changed, cell activated etc…these are specified in python and not in the xml.
    I hope this helps

    OK, thinks, I will try.