Hi Ricardo Abranches,
Based on the information provided, we understand that you want to prevent the ContextMenu from appearing on a right-click. This can be achieved by setting e.Cancel = true within the ContextMenuStrip.Opening event, which effectively disables the display of the ContextMenu.
To further assist you, we have prepared a sample demonstrating this approach. Please review the sample along with the accompanying code snippet, and let us know if this solution meets your requirements.
Code Snippet:
this.scheduleControl1.GetScheduleHost().ContextMenuStrip.Opening += ContextMenuStrip_Opening; // Event Customization private void ContextMenuStrip_Opening(object? sender, System.ComponentModel.CancelEventArgs e) { e.Cancel = true; } |
Attachment:
WinForms_ScheduleControl_b6f470b7.zip