<?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 Re: RibbonPanel.AddStackedItems and SplitButton in Revit API Forum</title>
    <link>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5950137#M68907</link>
    <description>&lt;P&gt;Dear&amp;nbsp;Michael,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Conhratulations on implementing your own workaround based on AdWindows.dll functionality.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please note that this is unsupported and you are using that at your own risk.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Would you like to share it with us, in case other people would like to incur that risk as well?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I will ask&amp;nbsp;the development team for you whether or not this omission is intentional.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;Best regards,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;Jeremy&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 14 Dec 2015 13:24:14 GMT</pubDate>
    <dc:creator>jeremytammik</dc:creator>
    <dc:date>2015-12-14T13:24:14Z</dc:date>
    <item>
      <title>RibbonPanel.AddStackedItems and SplitButton</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5949839#M68904</link>
      <description>&lt;P&gt;Currently ribbon SplitButtons can not be created using RibbonPanel.AddStackedItems method.&lt;/P&gt;&lt;P&gt;Only PushButtons, PulldownButtons, ComboBoxes and TextBoxes can be added this way.&lt;/P&gt;&lt;P&gt;Would it be possible to remove this limitation?&lt;/P&gt;</description>
      <pubDate>Mon, 14 Dec 2015 09:23:31 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5949839#M68904</guid>
      <dc:creator>mphelt</dc:creator>
      <dc:date>2015-12-14T09:23:31Z</dc:date>
    </item>
    <item>
      <title>Re: RibbonPanel.AddStackedItems and SplitButton</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5949953#M68905</link>
      <description>&lt;P&gt;Dear&amp;nbsp;Mphelt,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please take into consideration that the&amp;nbsp;user interface customisation possibilities supported by the Revit API are intentionally rather limited, in order to enforce a certain consistency across the default built-in UI and additional functionality provided by add-ins.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Therefore, you need to provide an extremely compelling reason for anything to be added.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please explain in detail exactly what you are trying to achieve and why it canot be achieved in any other manner.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Maybe the easiest way for you to move forward&amp;nbsp;will be to implement your own modal dialog within your own external command, in which you can implement your own user interface making use of the full range of possibilities offered by the .NET API.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;A slightly more complex and powerful approach would be to&amp;nbsp;implement a modeless form and user interface, again making full use of all .NET functionality, and communicate with your Revit add-in via external events, as demonstrated by the Revit SDK&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;ModelessForm_ExternalEvent sample.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;Best regards,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;Jeremy&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 14 Dec 2015 10:54:58 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5949953#M68905</guid>
      <dc:creator>jeremytammik</dc:creator>
      <dc:date>2015-12-14T10:54:58Z</dc:date>
    </item>
    <item>
      <title>Re: RibbonPanel.AddStackedItems and SplitButton</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5950120#M68906</link>
      <description>&lt;P&gt;Hi Jeremy,&lt;/P&gt;&lt;P&gt;What I wanted to achieve is a button similar to the selected one:&lt;/P&gt;&lt;P&gt;&lt;IMG src="https://forums.autodesk.com/t5/image/serverpage/image-id/206510iBCDC417EE159EA0F/image-size/original?v=mpbl-1&amp;amp;px=-1" alt="SplitButton.png" title="SplitButton.png" border="0" /&gt;&lt;/P&gt;&lt;P&gt;I've already overcome this using ribbon features from AdWindows.dll, but I was just curious whether tha lack of it in RevitAPIUI.dll is intentional or not.&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Michał Helt&lt;/P&gt;</description>
      <pubDate>Mon, 14 Dec 2015 13:10:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5950120#M68906</guid>
      <dc:creator>mphelt</dc:creator>
      <dc:date>2015-12-14T13:10:40Z</dc:date>
    </item>
    <item>
      <title>Re: RibbonPanel.AddStackedItems and SplitButton</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5950137#M68907</link>
      <description>&lt;P&gt;Dear&amp;nbsp;Michael,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Conhratulations on implementing your own workaround based on AdWindows.dll functionality.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please note that this is unsupported and you are using that at your own risk.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Would you like to share it with us, in case other people would like to incur that risk as well?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I will ask&amp;nbsp;the development team for you whether or not this omission is intentional.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;Best regards,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;Jeremy&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 14 Dec 2015 13:24:14 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5950137#M68907</guid>
      <dc:creator>jeremytammik</dc:creator>
      <dc:date>2015-12-14T13:24:14Z</dc:date>
    </item>
    <item>
      <title>Re: RibbonPanel.AddStackedItems and SplitButton</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5950194#M68908</link>
      <description>&lt;PRE&gt;var buttonData0 = new PulldownButtonData("A", "A");
var buttonData1 = new PulldownButtonData("B", "B");
var buttonData2 = new PulldownButtonData("C", "C");

var stackedItems =
  ribbonPanel.AddStackedItems(
  buttonData0,
  buttonData1,
  buttonData2
  );

var button0 = (PulldownButton)stackedItems[0];

var splitButton = (Autodesk.Windows.RibbonSplitButton)UIFramework.RevitRibbonControl.RibbonControl.findRibbonItemById(
  string.Join(
    "%", 
    "CustomCtrl_",
    "CustomCtrl_",
    ribbonTabName,
    ribbonPanel.Name,
    button0.Name
    ));
splitButton.IsSplit = true;
splitButton.IsSynchronizedWithCurrentItem = true;&lt;/PRE&gt;&lt;P&gt;Dear Jeremy,&lt;/P&gt;&lt;P&gt;That's the cleanest solution that I have found.&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Michał Helt&lt;/P&gt;</description>
      <pubDate>Mon, 14 Dec 2015 14:03:01 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5950194#M68908</guid>
      <dc:creator>mphelt</dc:creator>
      <dc:date>2015-12-14T14:03:01Z</dc:date>
    </item>
    <item>
      <title>Re: RibbonPanel.AddStackedItems and SplitButton</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5953685#M68909</link>
      <description>&lt;P&gt;Dear Michał,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you very much for sharing that!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It looks perfectly clean to me.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I added it to The Building Coder as wel to make it easier to find:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://thebuildingcoder.typepad.com/blog/2015/12/adding-a-stacked-split-button-to-the-ribbon.html" target="_blank"&gt;http://thebuildingcoder.typepad.com/blog/2015/12/adding-a-stacked-split-button-to-the-ribbon.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cheers,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Jeremy&lt;/P&gt;</description>
      <pubDate>Wed, 16 Dec 2015 11:39:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/ribbonpanel-addstackeditems-and-splitbutton/m-p/5953685#M68909</guid>
      <dc:creator>jeremytammik</dc:creator>
      <dc:date>2015-12-16T11:39:49Z</dc:date>
    </item>
  </channel>
</rss>

