This tag can be used in questions involving usage of MenuStrip class from Windows Forms (a GUI class library in the Microsoft .NET Framework).
Questions tagged [menustrip]
255 questions
25
votes
10 answers
Adding a horizontal separator in a MenuStrip
I can't seem to find any way to add a horizontal separator in a MenuStrip. Visual Studio complains Cannot add ToolStropSeparator to MenuStrip.
Any idea's how I can do this?

Malfist
- 31,179
- 61
- 182
- 269
19
votes
1 answer
How to remove MenuStrip submenu margins?
Do you know how to remove margin (probably the one for image and check box on the left and right) of the submenu in MenuStri? In MSDN article there is explained how to remove it from context menus. It is written that I should do it the same way in…

kyrisu
- 4,541
- 10
- 43
- 66
18
votes
8 answers
Move window without border
How do I move a window that does not have a border. There is no empty space on the application, all that is available is a webbrowser and a menustrip. I would like the users to be able to move the window by dragging the menu strip. How do I code…

Sean
- 8,401
- 15
- 40
- 48
14
votes
4 answers
Shortcuts Ctrl+C Ctrl+V dont work in Textboxes if MenuStrip has this Shortcuts set
Goal: A Menustrip with Copy and Paste and the user shall see the Shortcut-Keys.
Problem: If you have a MenuStrip and set the ShortcutKeys the are "catched" by the Menu but no longer by the Textboxes. This means you cannot use Ctrl+C / V in the…

user799821
- 218
- 2
- 10
11
votes
1 answer
Programmatically Adding Items To A Menu Strip?
Let's say I have a WinForm that has a menu strip in it. Let's say one of the items of this menu strip is named Cars.
Whenever I open my WinForm, I want to add a subitem under Cars for every car in a table.
Is this possible to do with code?

sooprise
- 22,657
- 67
- 188
- 276
8
votes
2 answers
How can I remove the white line drawn under a MenuStrip control?
I read a few other articles about how people want to customize the colors and gradients of a MenuStrip.
What I want to do is remove the gradient so that the MenuStrip is the same color as the rest of the form which, for me, is the default settings…

BrandNewDev
- 755
- 2
- 9
- 16
8
votes
1 answer
Adding label to menustrip
Is it possible to add a lable/toostriplabel to a menustrip in a c# winform?
I can't find an option to add it dierctly.
I want to add something that describes the status of a program, but I don't want to use a status bar for space.

Jerry
- 4,258
- 3
- 31
- 58
8
votes
2 answers
How to add things to a menustrip programatically?
I want to add whatever is written in a textbox to a menustrip. In the File > Recent Searches thing I have.
How can I do programatically? And can I assign an event handler dynamically so that when a user clicks on X item in that subfolder, the text…

Sergio Tapia
- 40,006
- 76
- 183
- 254
7
votes
5 answers
Winforms MenuStrip Underlined Hotkey Letter
Typically the hotkey letters on a MenuStrip are underlined. (&File, &Open, etc) On a project I'm working on the underline shows up in the designer, but not at run time. I can't find the property that controls this. Anyone out there know?

Jeff
- 8,020
- 34
- 99
- 157
7
votes
2 answers
Can I split a menu into multiple columns in WinForms?
A menu in an application of mine is going to contain too many items to be displayed in a single vertical row. Splitting it into 2 menus does not look a good solution as it would break UI semantics. Can I just set up one menu to be displayed with…

Ivan
- 63,011
- 101
- 250
- 382
7
votes
8 answers
Foreach every Subitem in a MenuStrip
I want to get all the SubItems of my MenuStrip, So I can change them all at once.
I'am trying things like the following, but they aren't working:
foreach (ToolStripMenuItem toolItem in menuStrip1.DropDownItems)
{
//Do something with toolItem…

Max
- 12,622
- 16
- 73
- 101
7
votes
1 answer
.NET MenuStrip with native Windows renderer?
Does anyone know how to have the MenuStrips to rendered with native Windows look and feel depending the OS version the user is using?
The current renders don't do it...
I'm currently using a third party control that can do it but uses MainMenu and…

rfgamaral
- 16,546
- 57
- 163
- 275
5
votes
2 answers
Can a MenuStrip control have its LayoutStyle set to StackWithOverflow?
I create a simple form with a MenuStrip. The MenuStrip's LayoutStyle is set to HorizontalStackWithOverflow (the default).
According to the MSDN reference on MenuStrip, its LayoutStyle property is inherited from ToolStrip. One of the possible values…

comecme
- 6,086
- 10
- 39
- 67
5
votes
3 answers
Change size of ToolStripMenuItem
I'm custom drawing a menu item in a MenuStrip. The problem I'm having is that the menu item insists on sizing itself based on the text, which is not what I want (there is no text). I can set AutoSize to false and explicitly specify a size, but the…

snarf
- 2,684
- 1
- 23
- 26
5
votes
1 answer
toolStrip to have menuStrip gradient background
I have a form with a menu and a toolstrip at the top. The menuStrip has a nice looking gradient background, how can I get the same effect on the toolStrip control? I know about the RenderMode property but changing this doesn't have the desired…

PaulK
- 623
- 2
- 10
- 22