Define ListBox inside ContextMenu

4 posts, 1 answers
  1. Naseem
    Naseem avatar
    70 posts
    Member since:
    Nov 2010

    Posted 10 Jan 2011 Link to this post

    Hello,

    I'm planning to create a ContextMenu for a GridView . I know how to implement it. Just I'm wondering if there is any way for showing listbox inside context menu . I mean when user goes on a MenuItem , instead of showing the child MenuItems , it shows list box  . I thought to define all of my items as sub MenuItems in codebehind , however in case the number of items are a lot , it's better to have them in a ListBox or something like this.

    I appreciate your help,

    Thank you so much.
  2. Answer
    Konstantina
    Admin
    Konstantina avatar
    2332 posts

    Posted 12 Jan 2011 Link to this post

    Hi Naseem,

    Thank you for contacting us.

    Instead of putting a ListBox in the ContextMenu, I can suggest you to implement a scrollable ContextMenu as explained in this help article.

    Hope this will help. Please let us know if you have any other questions about our controls.

    All the best,
    Konstantina
    the Telerik team
    Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
  3. DevCraft banner
  4. Naseem
    Naseem avatar
    70 posts
    Member since:
    Nov 2010

    Posted 12 Jan 2011 Link to this post

    Hello Konstantina ,

    Thank you so much for the quick answer .

    I have tried the solution you sent me . However that article is talking about RadMenu, not RadContextMenu . I have tried to change RadContextMenu Style but its style was different with the RadMenu and I'm not sure where I should put the ScrollViewer in RadContextMenu style as in RadMenu it's in Popup section and there is not Popup Section in RadContextMenu style. 

    <ScrollViewer MaxHeight="300"BorderThickness="0"
                                 Padding="0"
                                 VerticalScrollbarVisibility="Auto">
                       <ItemsPresenter />
    </ScrollViewer>

    Thank you Konstantina ,

    Kind Regards,
    Naseem
  5. Naseem
    Naseem avatar
    70 posts
    Member since:
    Nov 2010

    Posted 12 Jan 2011 Link to this post

    Hi Konstantina ,

    Sorry , my mistake . I should have changed RadMenuItem Style , not RadContextMenu . I did it and It's working nicely :)

    Thank you so much ,

    Kind Regards,
    Naseem
Back to Top