ContainerBindingCollection in WPF

6 posts, 1 answers
  1. Ben Boger
    Ben Boger avatar
    19 posts
    Member since:
    May 2010

    Posted 25 Feb 2011 Link to this post

    I am trying to get a CountainerBindingCollection and ContainBinding to work with my hierarchical data template in wpf but no matter what namespace I use it doesn't seem to recognize it.

    This link is to one of your WPF pages showing the ContainerBinding being used and it seems to be in the same namespace as the RadMenu , I have Access to the Menu but not the ContainerBindings, is this page of information wrong?

    At the bottom of this page there is a link 'to learn more about container bindings' which leads to a page that never even mentions the containerbinding
  2. Answer
    Hristo avatar
    832 posts

    Posted 25 Feb 2011 Link to this post

    Hi Ben Boger,

    ContainerBindnigs are only available for Silverlight. Their purpose is to workaround the missing Bindings in Style Setter. So you don't need them in WPF.
    If you want to enable/disable RadMenuItems you could use ItemContainerStyle property and set the following setter:
    <Style TargetType="telerik:RadMenuIte">
       <Setter Property="IsEnabled" Value="{Binding IsMenuItemEnabled}" />

    Where IsMenuItemEnabled is a property on your data item.

    We will update this article. Thanks for pointing it out.

    Kind regards,
    the Telerik team
    Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
  3. Louis
    Louis avatar
    86 posts
    Member since:
    Aug 2013

    Posted 26 Sep 2017 in reply to Hristo Link to this post

    You have the same problem in your RadComboBox WPF documentation:


  4. Martin Ivanov
    Martin Ivanov avatar
    2647 posts

    Posted 28 Sep 2017 Link to this post

    Hello Louis,

    Thank you for reporting this. I updated your Telerik points as a small gesture of gratitude for the report.

    Martin Ivanov
    Progress Telerik
    Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
  5. Darshan
    Darshan avatar
    4 posts
    Member since:
    Jun 2017

    Posted 04 Jun 2019 Link to this post

    The documentation for WPF still has the same problem.

    Also,Could you please guide me to the correct way to bind IsEnabled in a radcomboboxitem. Style Binding does not seem to work correctly.

  6. Martin Ivanov
    Martin Ivanov avatar
    2647 posts

    Posted 05 Jun 2019 Link to this post

    Hello Darshan,

    To bind the IsEnabled or any other property of RadComboBoxItem, use the approach shown in the Using Style Binding section of the article. I've attached a small example showing this approach. I hope it helps.

    Martin Ivanov
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Back to Top