Fusion API and Scripts
Got a new add-in to share? Need something specialized to be scripted? Ask questions or share what you’ve discovered with the community.
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Unable to disable "Control Definition"

Message 1 of 2
299 Views, 1 Reply

Unable to disable "Control Definition"

Hi All,

I am developing an Fusion360 Add-in (It is in C++), it consist of command definition. I am trying to disable it,

Following is the code block that I am  trying to implement.


Ptr<CommandDefinition> commandDefinitionPanel = commandDefinitions->itemById(commandIdOnPanel);
          if (!commandDefinitionPanel)
                  commandDefinitionPanel = commandDefinitions->addButtonDefinition(commandIdOnPanel, commandName, commandDescription, commandResources);

Code compiled and run successfully, but the button definition still enable.


Thanks in advance.

Message 2 of 2
in reply to: subhransuBAD5A

I thought I had replied to this earlier, sorry about the delay.  I did some quick testing when you originally posted this and am now writing a test case that I can use to file a bug.  I'm seeing something interesting in that it looks like the isVisible and isEnabled properties are working but then Fusion automatically sets them back after a few seconds.  I'm not exactly sure what's going on but I'll file the bug so it can be investigated and fixed.  Thanks for reporting this.

Brian Ekins
Inventor and Fusion 360 API Expert
Mod the Machine blog

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th

Autodesk Design & Make Report