<p>The <code>Open</code> button on the open file dialog used in certain windows applications includes a dropdown arrow with a list of additional options &mdash; namely <code>Open With..</code>.  </p>

<p><a href="https://i.stack.imgur.com/GLM3T.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/GLM3T.png" alt="Open File Dialog"></a></p>

<p>I haven't seen this in every Windows application, so you may have to try a few to get it, but SQL Server Management Studio and Visual Studio 2017 will both show the button that way if you go to the menu and choose <em><code>File</code>-><code>Open</code>-><code>File...</code></em></p>

<p>I want to use a button like this with a built-in list in one of my applications, but I can't find the control they're using anywhere in Visual Studio.  I should clarify that I'm looking for that specific button, not the entire dialog. Any thoughts?</p>

[{'answer_id': 31118, 'author': 'OwenP', 'author_id': 2547, 'author_profile': 'https://Stackoverflow.com/users/2547', 'pm_score': 1, 'selected': False, 'text': '<p>I don\'t think there\'s a built-in control that can do it in .NET.  I\'m poking around in the MSDN documentation for the standard Windows Button control, but it doesn\'t look like it\'s there.</p>\n\n<p>I did find a <a href="http://www.codeproject.com/KB/buttons/SplitButton.aspx" rel="nofollow noreferrer">Code Project article</a> with a custom implementation; this might help a little.</p>\n'}, {'answer_id': 31142, 'author': 'Neil Neyman', 'author_id': 3240, 'author_profile': 'https://Stackoverflow.com/users/3240', 'pm_score': 2, 'selected': False, 'text': "<p>I've not familiar with using either of these, but try searching msdn for splitbutton or dropdownbutton.  I think those are similar to what you're looking for.</p>\n"}, {'answer_id': 31190, 'author': 'Haydar', 'author_id': 288, 'author_profile': 'https://Stackoverflow.com/users/288', 'pm_score': 2, 'selected': False, 'text': "<p>I think what you are looking for is called a toolStripSplitButton. It is only available in a toolStrip. But you can add a toolStripContainer anywhere on your form and then put the toolStrip and toolStripSplitButton inside your container. </p>\n\n<p>You won't want to show the grips so you'll want to set your gripMargin = 0. You can also set your autosize=true so that the toolstrip conforms to your button.  The button will just look like a normal button (except for the split part) on your form.</p>\n"}, {'answer_id': 31195, 'author': 'Joel Coehoorn', 'author_id': 3043, 'author_profile': 'https://Stackoverflow.com/users/3043', 'pm_score': 0, 'selected': False, 'text': '<p>Since I found the control in Windows itself, I was hoping to find it built-in somewhere already so I didn\'t have to add anything to my code-base to use it.  But the split button at <a href="http://blogs.msdn.com/jfoscoding/articles/491523.aspx" rel="nofollow noreferrer">this link</a> (found via the msdn suggestion) looks pretty promising.</p>\n\n<p>I\'ll try it later myself, but I don\'t know how well it will handle visual styles.</p>\n'}, {'answer_id': 31202, 'author': 'Nick', 'author_id': 1490, 'author_profile': 'https://Stackoverflow.com/users/1490', 'pm_score': 2, 'selected': False, 'text': '<p>Here\'s my split button implementation.  It does not draw the arrow, and the focus/unfocus behavior is a little different.</p>\n\n<p>Both mine and the originals handle visual styles and look great with Aero.</p>\n\n<p><strong>Based on <a href="http://wyday.com/splitbutton/" rel="nofollow noreferrer">http://wyday.com/splitbutton/</a></strong></p>\n\n<pre><code>using System;\nusing System.Collections.Generic;\nusing System.Text;\nusing System.Windows.Forms;\nusing System.Windows.Forms.VisualStyles;\nusing System.Drawing;\nusing System.ComponentModel;\nusing System.Diagnostics;\n\n// Original: http://blogs.msdn.com/jfoscoding/articles/491523.aspx\n// Wyatt\'s fixes: http://wyday.com/splitbutton/\n// Trimmed down and redone significantly from that version (Nick 5/6/08)\nnamespace DF\n{\n    public class SplitButton : Button\n    {\n        private ContextMenuStrip m_SplitMenu = null;\n        private const int SplitSectionWidth = 14;\n        private static int BorderSize = SystemInformation.Border3DSize.Width * 2;\n        private bool mBlockClicks = false;\n        private Timer mTimer;\n\n        public SplitButton()\n        {\n            this.AutoSize = true;\n            mTimer = new Timer();\n            mTimer.Interval = 100;\n            mTimer.Tick += new EventHandler(mTimer_Tick);\n        }\n\n        private void mTimer_Tick(object sender, EventArgs e)\n        {\n            mBlockClicks = false;\n            mTimer.Stop();\n        }\n\n        #region Properties\n        [DefaultValue(null)]\n        public ContextMenuStrip SplitMenu\n        {\n            get\n            {\n                return m_SplitMenu;\n            }\n            set\n            {\n                if (m_SplitMenu != null)\n                    m_SplitMenu.Closing -= \n                        new ToolStripDropDownClosingEventHandler(m_SplitMenu_Closing);\n\n                m_SplitMenu = value;\n\n                if (m_SplitMenu != null)\n                    m_SplitMenu.Closing += \n                        new ToolStripDropDownClosingEventHandler(m_SplitMenu_Closing);\n            }\n        }\n\n        private void m_SplitMenu_Closing(object sender, ToolStripDropDownClosingEventArgs e)\n        {\n            HideContextMenuStrip();\n            // block click events for 0.5 sec to prevent re-showing the menu\n\n        }\n\n        private PushButtonState _state;\n        private PushButtonState State\n        {\n            get\n            {\n                return _state;\n            }\n            set\n            {\n                if (!_state.Equals(value))\n                {\n                    _state = value;\n                    Invalidate();\n                }\n            }\n        }\n\n        #endregion Properties\n\n        protected override void OnEnabledChanged(EventArgs e)\n        {\n            if (Enabled)\n                State = PushButtonState.Normal;\n            else\n                State = PushButtonState.Disabled;\n\n            base.OnEnabledChanged(e);\n        }\n\n        protected override void OnMouseClick(MouseEventArgs e)\n        {\n            if (e.Button != MouseButtons.Left)\n                return;\n            if (State.Equals(PushButtonState.Disabled))\n                return;\n            if (mBlockClicks)\n                return;\n\n            if (!State.Equals(PushButtonState.Pressed))\n                ShowContextMenuStrip();\n            else\n                HideContextMenuStrip();\n        }\n\n        protected override void OnMouseEnter(EventArgs e)\n        {\n            if (!State.Equals(PushButtonState.Pressed) &amp;&amp; !State.Equals(PushButtonState.Disabled))\n            {\n                State = PushButtonState.Hot;\n            }\n        }\n\n        protected override void OnMouseLeave(EventArgs e)\n        {\n            if (!State.Equals(PushButtonState.Pressed) &amp;&amp; !State.Equals(PushButtonState.Disabled))\n            {\n                if (Focused)\n                {\n                    State = PushButtonState.Default;\n                }\n\n                else\n                {\n                    State = PushButtonState.Normal;\n                }\n            }\n        }\n\n        protected override void OnPaint(PaintEventArgs pevent)\n        {\n            base.OnPaint(pevent);\n\n            Graphics g = pevent.Graphics;\n            Rectangle bounds = this.ClientRectangle;\n\n            // draw the button background as according to the current state.\n            if (State != PushButtonState.Pressed &amp;&amp; IsDefault &amp;&amp; !Application.RenderWithVisualStyles)\n            {\n                Rectangle backgroundBounds = bounds;\n                backgroundBounds.Inflate(-1, -1);\n                ButtonRenderer.DrawButton(g, backgroundBounds, State);\n\n                // button renderer doesnt draw the black frame when themes are off =(\n                g.DrawRectangle(SystemPens.WindowFrame, 0, 0, bounds.Width - 1, bounds.Height - 1);\n            }\n            else\n            {\n                ButtonRenderer.DrawButton(g, bounds, State);\n            }\n\n            StringFormat format = new StringFormat();\n            format.Alignment = StringAlignment.Center;\n            format.LineAlignment = StringAlignment.Center;\n\n            g.DrawString(Text, Font, SystemBrushes.ControlText, bounds, format);\n        }\n\n        private void ShowContextMenuStrip()\n        {\n            State = PushButtonState.Pressed;\n            if (m_SplitMenu != null)\n            {\n                m_SplitMenu.Show(this, new Point(0, Height), ToolStripDropDownDirection.BelowRight);\n            }\n        }\n\n        private void HideContextMenuStrip()\n        {\n            State = PushButtonState.Normal;\n            m_SplitMenu.Hide();\n            mBlockClicks = true;\n            mTimer.Start();\n        }\n    }\n}\n</code></pre>\n'}, {'answer_id': 31262, 'author': 'Will Dean', 'author_id': 987, 'author_profile': 'https://Stackoverflow.com/users/987', 'pm_score': 4, 'selected': True, 'text': '<p>I used the draggable search in Spy++ (installed with VS) to look at the split open button on the file-open dialog of VS.</p>\n\n<p>This revealed that it\'s an ordinary windows button with a style which includes BS_DEFSPLITBUTTON.   That\'s a magic keyword which gets you to some interesting places, including</p>\n\n<p><a href="http://www.codeplex.com/windowsformsaero/SourceControl/FileView.aspx?itemId=212902&amp;changeSetId=9930" rel="noreferrer">http://www.codeplex.com/windowsformsaero/SourceControl/FileView.aspx?itemId=212902&amp;changeSetId=9930</a></p>\n\n<p>and here</p>\n\n<p><a href="http://msdn.microsoft.com/en-us/library/bb775949.aspx#using_splits" rel="noreferrer">http://msdn.microsoft.com/en-us/library/bb775949.aspx#using_splits</a></p>\n\n<p>Hope this helps you.  </p>\n\n<p>EDIT:</p>\n\n<p>I\'ve actually just tried that code from CodePlex and it does create a split button - but you do have to make sure you\'ve set the button\'s FlatStyle to \'System\' rather than \'Standard\' which is the default.   I\'ve not bothered to hook-up the event handling stuff for the drop-down, but that\'s covered in the MSDN link, I think.</p>\n\n<p>Of course, this is Vista-only (but doesn\'t need Aero enabled, despite the name on codeplex) - if you need earlier OS support, you\'ll be back to drawing it yourself.</p>\n'}, {'answer_id': 1584713, 'author': 'David Vidmar', 'author_id': 11063, 'author_profile': 'https://Stackoverflow.com/users/11063', 'pm_score': 3, 'selected': False, 'text': '<p>I remembered that <a href="http://ketarin.canneverbe.com/" rel="nofollow noreferrer" title="Ketarin">Ketarin</a> has a button like that. </p>\n\n<p>Using <a href="http://www.red-gate.com/products/reflector/" rel="nofollow noreferrer" title="Reflector">Reflector</a> I found great open source control called <a href="http://wyday.com/splitbutton/" rel="nofollow noreferrer" title="wyDay.SplitButton">wyDay.SplitButton</a>.\n<img src="https://i.stack.imgur.com/yDT06.png" alt="wyDay.SplitButton"></p>\n'}]
['https://Stackoverflow.com/questions/31090', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/3043/']