Hi All,
How do you allow items in a toolstrip to be movable? For example, the toolstrips in MS Word 2003.
Is it possible to allow items within a toolstrip to be moved around at run time?
Printable View
Hi All,
How do you allow items in a toolstrip to be movable? For example, the toolstrips in MS Word 2003.
Is it possible to allow items within a toolstrip to be moved around at run time?
You can do it by changing the ToolStrip's AllowItemReorder to True. Each item within the control can then by dragged, at runtime, while the Alt key is held down.
Select the ToolStrip, click the little arrow on its top-right corner and select "Enbed in ToolStripContainer. You can now drag the TooStrip to any edge of the form. Floating tool bars are not supported as standard. You would have to write a fair amount of custom code or else get a third-party component for that.
I'm not sure exactly, jmcilhinney, but I think that Giraffe Frenzy just wants to move the items within the ToolStrip as opposed to moving the ToolStrip within the ToolStripContainer.
PS: Do you know of any third party ToolStrips that can float or any code to do so?
You may be right about that. Given that you can't just move tool bar items at will I didn't think of that, but the Customize feature is not supported as standard by the ToolStrip component. I'm sure there are plenty fo third-party components that do, although they are probably expensive.Quote:
Originally Posted by dom_stapleton
dom is correct,
I would like to be able to move the items within the toolbar. I was hoping there was a built in feature to do so.
Creating your own Customise dialog is relatively easy to do, but using the AllowItemReorder property is the simplest way.