title: How to access a styles resources and retrieve an inner style that doesn't have a key
body: <p>I have a style for a stack panel which has a key, within the stack panel I have buttons which have a default style set via the stack panel's Style > Resources > Styles, for this reason the buttons style is not set via a key but instead is set as it is a child of the stack panel! I'm sure this is a little tricky to understand as it sure feels tricky to explain... here is the style code...</p>
  
  <pre><code>&lt;Style x:Key="VerticalMenuPanel" TargetType="{x:Type StackPanel}"&gt;
      &lt;Setter Property="Background" Value="#115e9a" /&gt;
  
      &lt;Style.Resources&gt;
          &lt;Style TargetType="{x:Type Button}"&gt;
              &lt;Setter Property="Background" Value="Transparent" /&gt;
              &lt;Setter Property="Margin" Value="0,0,0,0" /&gt;
              &lt;Setter Property="Foreground" Value="White" /&gt;
              &lt;Setter Property="FontSize" Value="13" /&gt;
              &lt;Setter Property="FontFamily" Value="Calibri" /&gt;
              &lt;Setter Property="FontWeight" Value="Bold" /&gt;
              &lt;Setter Property="Height" Value="27" /&gt;
              &lt;Setter Property="Template"&gt;
                  &lt;Setter.Value&gt;
                      &lt;ControlTemplate TargetType="{x:Type Button}"&gt;
                          &lt;Border BorderBrush="White" BorderThickness="0,0,0,1"&gt;
                              &lt;Border BorderBrush="#0160a2" BorderThickness="0,0,0,1.5"&gt;                                
                                  &lt;ContentPresenter VerticalAlignment="Center" /&gt;
                              &lt;/Border&gt;
                          &lt;/Border&gt;
                      &lt;/ControlTemplate&gt;
                  &lt;/Setter.Value&gt;
              &lt;/Setter&gt;
          &lt;/Style&gt;
      &lt;/Style.Resources&gt;
  &lt;/Style&gt;
  </code></pre>
  
  <p>So, basically, without getting into what I'm doing too much I require the need to change the style of the buttons within the stack panel based on certain events. In order to change the style I simply find the resource based on the style key! HOWEVER here is my problem, I can't reset the style back to the "default" style provided by the parent the "VerticalMenuPanel"s Style.Resources as I don't know how to retrieve the style without having a definitive key for it. The obvious thing to do would be to give the button style a key but then I would have to explicitly define the style for all of the buttons instead of the style being applied by default as it is a child of the stack panel!</p>
  
  <p>The bottom line is how do I retrieve a style without a key from within a parent styles resources (programatically)? Obviously I can retrieve the parent style via its key. </p>
  
  <p>I hope you understand the issue I am having, and please feel free to let me know if I can explain anything better, add more clarity or if you wish edit the post yourself :)</p>