How to add command/button to AETemplate?

How to add command/button to AETemplate?

Anonymous
Not applicable
1,211 Views
2 Replies
Message 1 of 3

How to add command/button to AETemplate?

Anonymous
Not applicable
I'm trying to integrate a simulator into Maya. I have a solver node. I would like to put a button on the attribute editor, "Simulate" for example that calls a command. How can this be achieved with AETemplates and MEL?
0 Likes
Accepted solutions (1)
1,212 Views
2 Replies
Replies (2)
Message 2 of 3

haggi_master
Advocate
Advocate
Accepted solution

Do you like to see the answer here or at StackOverflow?

Message 3 of 3

Anonymous
Not applicable

Thanks. I marked your solution on Stack overflow as the right one. I had discovered something similar, and hacked an example for a file input attribute to put a button there. i will refactor with your solution, thanks again.

 

 

// My hack, which I put in the new function of -callCustom

setUITemplate -pst attributeEditorTemplate;
        columnLayout -adj true;
            button -label "Simulate" -c "ArenaSimulateCommand";
        setParent ..;
    setParent ..;

    setUITemplate -ppt;
    setParent ..;

0 Likes