Property "Command" does not have an accessible setter

2 posts, 1 answers
  1. Pierre
    Pierre avatar
    23 posts
    Member since:
    Oct 2015

    Posted 20 Jan Link to this post

    I can't get rid of a XAML designer error.

    <UserControl x:Class="MenuItemBinding.SomeUserControl"
                 xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                 xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation">
       <Grid>
          <telerik:RadMenu>
             <telerik:RadMenuItem Header="Hello World" Command="{Binding HelloWorld}" />
          </telerik:RadMenu>
       </Grid>
    </UserControl>
     

     The 'Command="{Binding' part has a green underline with the tooltip "The property "Command" does not have an accessible setter".

    Observations:

    • Only happens in x64 (x86 doesn't show this error).
    • Seems to only happen with RadMenuItem although I have not check all cases.
    • It happens regardless where I place the RadMenuItem in the XAML.
    • The application still works fine even though the XAML designer is stuck to "Invalid Markup"

    How do I get rid of this error?

  2. Answer
    Nasko
    Admin
    Nasko avatar
    585 posts

    Posted 22 Jan Link to this post

    Hi Pierre,

    Since the release of Visual Studio 2015 (which we believe you are using) we have hit several issues with its designer. We isolated and reported most of them to Microsoft. One of these issues is the one you are currently observing:
    https://connect.microsoft.com/VisualStudio/feedback/details/2006584/designer-error-the-property-command-does-not-have-an-accessible-setter-for-a-control-implementing-icommandsource-in-wpf-application-with-x64-platform-target

    In the comments Microsoft stated that fix should be available with the next update of VS 2015.

    Hope the provided information will be helpful for you.

    Regards,
    Nasko
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for WPF is Visual Studio 2017 Ready
Back to Top