C1MenuItem Command-Binding error

Posted by: stefan.nerlich on 16 July 2018, 8:03 pm EST

    • Post Options:
    • Link

    Posted 16 July 2018, 8:03 pm EST

    Hi everyone,

    the following Command-Binding works as expected:

    
    <c1:C1MenuItem Header="{DynamicResource StrImportFromFile}" Command="{Binding ReadCommand}" CommandParameter="FILE"/>
    
    

    Command-Binding not working here:

    
    <c1:C1MenuItem Command="{Binding ReadCommand}" CommandParameter="DB">
     <c1:C1MenuItem.Header>
      <TextBlock>
       <Run Text="{DynamicResource StrDatabase}"/>
       <Run Text="{DynamicResource StrPunctuation}"/>
      </TextBlock>
     </c1:C1MenuItem.Header>
    </c1:C1MenuItem>
    
    

    Thank you!

  • Posted 17 July 2018, 10:48 pm EST

    Hi,

    It looks the binding has to be the problem here. So, could you please check out the binding errors in debug window.

    Also, I suggest you to use RelativeSource in your binding, as direct binding might not be able to provide what you want.

    If it does not help, could you share a demo application to demonstrate the issue. I could then work over the same and try to find the cause & its resolution.

    Thanks,

    Ruchir

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels