<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Adding and removing a TabCommandInput on the fly in Fusion API and Scripts Forum</title>
    <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/adding-and-removing-a-tabcommandinput-on-the-fly/m-p/8178015#M15720</link>
    <description>&lt;P&gt;I am trying to change the UI in reaction to some input change, but it looks like nothing is reacting.&lt;/P&gt;&lt;P&gt;here is a test (using Fusion360AddinSkeleton):&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;class &lt;/SPAN&gt;TestTabCommand(Fusion360CommandBase):&lt;BR /&gt;    &lt;SPAN&gt;def &lt;/SPAN&gt;&lt;SPAN&gt;on_input_changed&lt;/SPAN&gt;(&lt;SPAN&gt;self&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;command: Command&lt;SPAN&gt;, &lt;/SPAN&gt;inputs: CommandInputs&lt;SPAN&gt;, &lt;/SPAN&gt;changed_input&lt;SPAN&gt;, &lt;/SPAN&gt;input_values):&lt;BR /&gt;        &lt;SPAN&gt;if &lt;/SPAN&gt;changed_input.id == &lt;SPAN&gt;'test'&lt;/SPAN&gt;:&lt;BR /&gt;            AppObjects().ui.messageBox(&lt;SPAN&gt;'adding tab'&lt;/SPAN&gt;)&lt;BR /&gt;            &lt;SPAN&gt;self&lt;/SPAN&gt;.inputs.addTabCommandInput(&lt;SPAN&gt;'general_tab'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'New Tab'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;''&lt;/SPAN&gt;)&lt;BR /&gt;&lt;BR /&gt;    &lt;SPAN&gt;def &lt;/SPAN&gt;&lt;SPAN&gt;on_create&lt;/SPAN&gt;(&lt;SPAN&gt;self&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;command: Command&lt;SPAN&gt;, &lt;/SPAN&gt;inputs: CommandInputs):&lt;BR /&gt;        &lt;SPAN&gt;self&lt;/SPAN&gt;.inputs = inputs&lt;BR /&gt;        general_tab = inputs.addTabCommandInput(&lt;SPAN&gt;'general_tab'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'General'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;''&lt;/SPAN&gt;)&lt;BR /&gt;        general_tab.children.addBoolValueInput(&lt;SPAN&gt;'test'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'test'&lt;/SPAN&gt;&lt;SPAN&gt;, False&lt;/SPAN&gt;)&lt;BR /&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;When clicking on the 'test' button, the messageBox shows, but no new tab appears.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a way to customize the UI on the fly?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your help,&lt;/P&gt;&lt;P&gt;Nicolas.&lt;/P&gt;</description>
    <pubDate>Sat, 04 Aug 2018 23:53:05 GMT</pubDate>
    <dc:creator>nraynaud</dc:creator>
    <dc:date>2018-08-04T23:53:05Z</dc:date>
    <item>
      <title>Adding and removing a TabCommandInput on the fly</title>
      <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/adding-and-removing-a-tabcommandinput-on-the-fly/m-p/8178015#M15720</link>
      <description>&lt;P&gt;I am trying to change the UI in reaction to some input change, but it looks like nothing is reacting.&lt;/P&gt;&lt;P&gt;here is a test (using Fusion360AddinSkeleton):&lt;/P&gt;&lt;PRE&gt;&lt;SPAN&gt;class &lt;/SPAN&gt;TestTabCommand(Fusion360CommandBase):&lt;BR /&gt;    &lt;SPAN&gt;def &lt;/SPAN&gt;&lt;SPAN&gt;on_input_changed&lt;/SPAN&gt;(&lt;SPAN&gt;self&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;command: Command&lt;SPAN&gt;, &lt;/SPAN&gt;inputs: CommandInputs&lt;SPAN&gt;, &lt;/SPAN&gt;changed_input&lt;SPAN&gt;, &lt;/SPAN&gt;input_values):&lt;BR /&gt;        &lt;SPAN&gt;if &lt;/SPAN&gt;changed_input.id == &lt;SPAN&gt;'test'&lt;/SPAN&gt;:&lt;BR /&gt;            AppObjects().ui.messageBox(&lt;SPAN&gt;'adding tab'&lt;/SPAN&gt;)&lt;BR /&gt;            &lt;SPAN&gt;self&lt;/SPAN&gt;.inputs.addTabCommandInput(&lt;SPAN&gt;'general_tab'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'New Tab'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;''&lt;/SPAN&gt;)&lt;BR /&gt;&lt;BR /&gt;    &lt;SPAN&gt;def &lt;/SPAN&gt;&lt;SPAN&gt;on_create&lt;/SPAN&gt;(&lt;SPAN&gt;self&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;command: Command&lt;SPAN&gt;, &lt;/SPAN&gt;inputs: CommandInputs):&lt;BR /&gt;        &lt;SPAN&gt;self&lt;/SPAN&gt;.inputs = inputs&lt;BR /&gt;        general_tab = inputs.addTabCommandInput(&lt;SPAN&gt;'general_tab'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'General'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;''&lt;/SPAN&gt;)&lt;BR /&gt;        general_tab.children.addBoolValueInput(&lt;SPAN&gt;'test'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'test'&lt;/SPAN&gt;&lt;SPAN&gt;, False&lt;/SPAN&gt;)&lt;BR /&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;When clicking on the 'test' button, the messageBox shows, but no new tab appears.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a way to customize the UI on the fly?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your help,&lt;/P&gt;&lt;P&gt;Nicolas.&lt;/P&gt;</description>
      <pubDate>Sat, 04 Aug 2018 23:53:05 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/adding-and-removing-a-tabcommandinput-on-the-fly/m-p/8178015#M15720</guid>
      <dc:creator>nraynaud</dc:creator>
      <dc:date>2018-08-04T23:53:05Z</dc:date>
    </item>
    <item>
      <title>Re: Adding and removing a TabCommandInput on the fly</title>
      <link>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/adding-and-removing-a-tabcommandinput-on-the-fly/m-p/8178017#M15721</link>
      <description>&lt;P&gt;uh! I asked the same question last year:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://forums.autodesk.com/t5/fusion-360-api-and-scripts/adding-an-input-to-a-command-dynamically/m-p/7540633#M5039" target="_blank"&gt;https://forums.autodesk.com/t5/fusion-360-api-and-scripts/adding-an-input-to-a-command-dynamically/m-p/7540633#M5039&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 04 Aug 2018 23:56:21 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/fusion-api-and-scripts-forum/adding-and-removing-a-tabcommandinput-on-the-fly/m-p/8178017#M15721</guid>
      <dc:creator>nraynaud</dc:creator>
      <dc:date>2018-08-04T23:56:21Z</dc:date>
    </item>
  </channel>
</rss>

