Editor in a Project Wizard

Options
Ayush Kumar
Ayush Kumar Member, Moderator, Employee Posts: 416
First Anniversary Ansys Employee Solution Developer Community of Practice Member First Answer
edited December 2022 in General Language Questions

Editor in a Project Wizard

Tagged:

Answers

  • Ayush Kumar
    Ayush Kumar Member, Moderator, Employee Posts: 416
    First Anniversary Ansys Employee Solution Developer Community of Practice Member First Answer
    Answer ✓
    Options

    This needs a custom layout for the wizard. Add the following ComponentRenderer to the UI layout in the XML

    <component 
        name="MyEditor"
        topAttachment="Title"
        leftAttachment="Properties"
        rightAttachment=""
        rightOffset="10"
        bottomAttachment="Chart"
        widthType="Percentage"
        width="25"
        heightType="Percentage"
        height="50"
        maxHeight="50"
        componentType="editorComponent" />
    

    The text in the Editor can be retrieved via the following python command:

    my_editor = step.UserInterface.GetComponent("MyEditor")
    text = my_editor.Content
    

    Editor

    Different ComponentRenderers in WB