Control Naming when using RadDocking

2 posts, 0 answers
  1. David
    David avatar
    13 posts
    Member since:
    Aug 2012

    Posted 29 Mar 2012 Link to this post

    I have this issue when using the docking control that I must ensure that RadPanes do not contain controls with the same name otherwise I get an error saying that it already exists in the visual tree. Is this behaviour correct or am I doing something fundamentally wrong?

    I thought it would be fine to have 2 controls with the same name aslong as they are hosted in 2 differently named radPanes??

    Help on this would be greatly appreciated.

    I should add that I'm using PRISM with this project.
  2. Miroslav Nedyalkov
    Miroslav Nedyalkov avatar
    1718 posts

    Posted 04 Apr 2012 Link to this post

    Hi David,

    You cannot have two controls with the same names in the Docking control - this is because the panes doesn't create a new name scope and the framework doesn't allow existence of two elements with the same name in the same name scope.
    Using the same  name scope for the content of all the panes is needed as when defining the panes in the same XAML file and placing names to their children, the framework generates fields for them and we want to keep these fields working correctly.

    Hope this information is helpful.

    Miroslav Nedyalkov
    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
  3. DevCraft banner
Back to Top