🎉Community Raffle - Win $25

An exclusive raffle opportunity for active members like you! Complete your profile, answer questions and get your first accepted badge to enter the raffle.
Join and Win

Auto change current component after excuting a command from pushpanel

User: "Yu-Ju Chen_20500"
Altair Community Member
Updated by Yu-Ju Chen_20500

I wrote a tcl script to auto change current component after I excute a command from pushpanel.

 

Here is my script:

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

hm_pushpanel {velocities}

set loadid [hm_info currentcollector loadcol]
incr loadid
if {[hm_entityinfo exist loadcol $loadid -byid] == 1} {
    set loadname [hm_getentityvalue loadcol $loadid name 1 -byid]
    *retainmarkselections 1
    *currentcollector loadcol '$loadname'
    *retainmarkselections 0

} else {
    return
}

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

 

I'll call out a  pushpanel first, in this example : velocities panel.

 

And I will create an initial velocity for current component and press the create button in this panel.

I know how to change the current component.

I have no idea about how to write the command script after pressing the create button and then change the current component to the next component. 

 

Does anyone can help me?

<?xml version="1.0" encoding="UTF-8"?>Screenshot - 2019_5_3 , 12_11_50.png

Find more posts tagged with

Sort by:
1 - 2 of 21
    User: "tinh"
    Altair Community Member
    Updated by tinh

    A right programming flow is : make the script to create loads instead of clicking

    User: "Yu-Ju Chen_20500"
    Altair Community Member
    OP
    Updated by Yu-Ju Chen_20500

    A right programming flow is : make the script to create loads instead of clicking

    Hi, Tinh,

    Thanks for your reply!