0

Here is a HelpPaneContentTemplate:

<r:Ribbon.HelpPaneContentTemplate>
                <DataTemplate>
                    <StackPanel Orientation="Horizontal">
                        <TextBlock 
                            Name="lbl_Help" 
                            Text="1234" 
                            VerticalAlignment="Center"  />
                        <r:RibbonButton 
                            Name="rbhelp"
                            SmallImageSource="Icons/help.ico" 
                            Command="Help" 
                    />
                    </StackPanel>
                </DataTemplate>
            </r:Ribbon.HelpPaneContentTemplate>

The Question I have -> How am I able to access the TextBlock (Named lbl_Help here) to update the Text from Codebehind? I tried to use "FindName" but I don't know how to reference to the HelpPaneContentTemplate to call Findname correctly.

Frank
  • 1
  • 1
  • Possible duplicate of [WPF How to access control from DataTemplate](https://stackoverflow.com/questions/4586106/wpf-how-to-access-control-from-datatemplate) – Rekshino Feb 21 '18 at 15:04
  • I found the answer for me here: https://stackoverflow.com/questions/9715918/acces-textblock-text-inside-a-buttonstyle-from-codebehind – Frank Feb 21 '18 at 15:49
  • Thanks Rekshino, your Link, linked me to the right answer – Frank Feb 21 '18 at 15:53

0 Answers0