views:

41

answers:

1

Hello, I'm using silverlight and I defined two styles for the page:

  • ExpanderBottomRightButtonStyle
  • ExpanderScaleStyle

Now I want to add those two styles to the same control:

<controls:Expander x:Name="expBRButton" Grid.Row="1" Grid.Column="2" Margin="5" Style="{StaticResource ExpanderBottomRightButtonStyle}">
            <controls:Expander.Content>
                <Button Content="&lt;Button&gt;"></Button>
            </controls:Expander.Content>
        </controls:Expander>

I don't want to join the two styles in one, cause I need them separately too.

I thought something like:

Style="{StaticResource ExpanderBottomRightButtonStyle ExpanderScaleStyle}"

But it's not possible. How should I do this?

I'm new on Silverlight 3.

Thanks in advance.

A: 

The closest you can get using styles alone is to create a third style and specify its BasedOn property pointing at one of your existing styles. You would then need to duplicate the contents of the other style.

Not a very satisfactory solution, however, I've never found a need for this myself.

AnthonyWJones
Thanks for your answer, I'll try it.
lidermin