Hi,
I have used the layout Control to help us manage the UI's control, and I have assigned one generic context menu strip, I have added one gridControl. when I right-click on the gridcontrol's column header, which will show the default column context menu, but the Layout Control's context menu has been fired as well.
Could you please help me, how to resolve the issue?
I have attached the form and screenshot.
Thanks in advance!
Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.
Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.
Hi,
In your screenshot, a standard GridView menu is shown. You can suppress it by handling the GridView.PopupMenuShowing event and setting the e.Allow parameter to false. Another approach is to use the GridView.OptionsMenu property. However, if you want to have a menu that has a consistent appearance with other menus, we suggest that you use the e.Menu parameter to add custom items to the default menu.
Thanks
Dimitros
Hi Dimitros,
Thanks for your help, I want to suppress the contextMenuStrip and display the gridview's menu.
I could not get the information, the right-click fired on one "GridView" control.
Thanks and best regards!
Hi,
The GridView does not manage standard context menus. You can suppress it from opening using the capabilities provided by the ContextMenuStrip component. For example, you can handle its Opening event, and set the Cancel parameter to true.
private void contextMenuStrip1_Opening(object sender, CancelEventArgs e) { e.Cancel = gridControl1.Bounds.Contains(gridControl1.PointToClient(MousePosition)); }
Thanks,
Uriah.
It's fixed
It's fixed
It's fixed