customized context menu

2 posts, 0 answers
  1. asif
    asif avatar
    12 posts
    Member since:
    Aug 2006

    Posted 02 Feb 2011 Link to this post

    I am implementing customized items in context menu where one of the menu items have sub items (children) elments but the problem is that when i take the mouse on sub items(childrens) the sub items still remain non-highlited.....and also the click event gets called on double click not on single click.

    Also tell me Is there any possibility of implementing sub menu item like there is available in word (attached file).

    I need examples in windows forms not on web.

    Please help me how to highlight those items on "mouse over".

  2. Stefan
    Stefan avatar
    2891 posts

    Posted 07 Feb 2011 Link to this post

    Hello asif,

    Thank you for writing.

    You can easily create a context menu like the one on the provided image by using of RadContextMenu. For this purpose, simply add from the Toolbox RadContextMenuManager and RadContextMenu. Then, in the property grid of the form assign the instance of the context menu (radContextMenu1 in this case) to the RadContextMenu property of the form. Now all that is left is to add the desired RadMenuItems, RadComboBoxItems or RadSeparatorItems to the context menu. You can customize them with images which will appear before the menu item, just like in the screen shot, you can change their colors, etc. Finally, you can subscribe to the Click event of the desired items and put your logic there. 

    Attached, you can find a sample project demonstrating this. At this link you can find our documentation regarding RadContextMenu.

    Let me know if you need further assistance.

    All the best,
    the Telerik team
    Q3’10 SP1 of RadControls for WinForms is available for download; also available is the Q1'11 Roadmap for Telerik Windows Forms controls.
  3. DevCraft banner
Back to Top