293 questions
0 votes
0 answers
14 views
WinForms: Bug when using ComboBox in ContextMenuStrip with ToolStripControlHost [duplicate]
Summary: If you create a ComboBox, put in inside a ToolStripControlHost, and then add the latter to the Items collection of a ContextMenuStrip - then clicking on a ComboBox item which hangs below the ...
0 votes
1 answer
51 views
C# Windows - DataGridViewComboBoxCell not being cleared from a DataGridView
I'm using VS 2022 C# Windows. I have a DataGridView that will display a DataGridViewComboBoxCell, depending on the col selected. private void dgv_CurrentCellChanged(object sender, EventArgs e) ...
1 vote
0 answers
66 views
C# ContextMenuScript cause GCHandle leak and Memory Leak in .Net Framework
I developed an application in .net framework 4.8, it can show, switch and close different .net displays via commands with many controls inside of the display again and again, I cannot hold them in ...
1 vote
1 answer
286 views
How to make variable height for ToolStripMenuItems in ContextMenuStrip?
I need to have multiline items, but then every other item height become same as multiline. I don't understand how to control it's height. On the picture below, 3 other items have same height as the ...
0 votes
1 answer
140 views
ToolStripMenuItem.Checked property does not set C# WinForms
I made a music player in C# and the only problem is the playlists context menu strip when you right click on the track. When the music is in a playlist, it checks; when it is not in a playlist, it is ...
0 votes
1 answer
172 views
How to remove checked margin in tray icon context menu
I've created this little script running in tray. I've noticed that contex menu text is not placed completely to the left. After a little investigation I found out that it is because there is a space ...
-1 votes
1 answer
243 views
Why is the option to add a ContextMenuStrip greyed out in the toolbox in Visual Studio 2022?
I've been googling for hours and can't seem to resolve this or add a ContextMenuStrip in via code (as I'm still learning) Ideally I would like the option to not be greyed in VS2022 as it would make ...
0 votes
0 answers
86 views
Measure ToolStripItem in custom ToolStrip renderer
I have a WinForms app for .NET Framework in which the text of items in context menus based on the the ContextMenuStrip component are drawn using Graphics.DrawString() to provide consistent look with ...
0 votes
1 answer
237 views
Winforms' ContextmenuStrip and ChromiumWebBrowser
I need to show Winforms ContextMenuStrip but ChromiumWebBrowser gets in the way. By getting in the way I mean the ContextMenuStrip loses some of its significant behavior like the ability to process ...
1 vote
2 answers
257 views
C# how to get referece to ContextMenuStrip from underlying sub menuitems of at least two levels
How to get the referece to ContextMenuStrip from its underlying sub menuitem which is a ToolStripMenuItem of a ToolStripDropDownMenu which is a Dropdown of a ToolstripMenuItem of this ContextMenuStrip?...
1 vote
2 answers
923 views
How to position a Popup Menu to the left side of a Button?
I have a Popup menu. The Popup menu has a two-column layout. Therefore, the Buttons are aligned in two columns, which are the left column and the right column. Inside it, there are Buttons. Upon ...
0 votes
0 answers
163 views
ContextMenuStrip not copying to clipboard
This may be more of a RANT than question. That said the ContextMenuStrip is the worst control I have ever used.. Here is the process I added a ContextMenuStrip (CMS) to a RichTextBox then used a mouse ...
0 votes
1 answer
647 views
Why ContextMenuStrip is not opening at first time click from a button in C#?
I am currently developing a Matrix(layout) Popup Menu using a Form. Inside the popup menu, there's a Button. The button should open a ContextMenuStrip when left clicked, but not right clicked. With ...
0 votes
0 answers
90 views
Stuck ContextMenuStrip In Bottom Of Form
i use a scrollable form in visual studio 2022,also i use contextmenustrip.problem is when the form is long,contextmenustrip doesn't in right place in design time so i can't use it,it's mean i can't ...
0 votes
1 answer
29 views
ContextMenuStrip disappears after a quarter second display
Well, I'm back. I solved the ListBox problem by using a ContextMenuStrip — or so I thought! It comes in perfect, then in a quarter second, two things happen: it disappears, and the TreeNode ...