Which XAML fragment should you use?

You are developing a Silverlight 4 application.
You need to create an implicit style for a ComboBox that specifies the following settings:
FontFamily = Verdana
Foreground = Green
Which XAML fragment should you use?

You are developing a Silverlight 4 application.
You need to create an implicit style for a ComboBox that specifies the following settings:
FontFamily = Verdana
Foreground = Green
Which XAML fragment should you use?

A.
<Style TargetType=”ComboBox”>
<Setter Property=”FontFamily” Value=”Verdana” />
<Setter Property=”Foreground” Value=”Green” />
</Style>

B.
<Style x:Key=”StandardComboBox” TargetType=”ComboBox”>
<Setter Property=”FontFamily” Value=”Verdana” />
<Setter Property=”Foreground” Value=”Green” />
</Style>

C.
<Style x:Name=”StandardComboBox”>
<Setter Property=”FontFamily” Value=”Verdana” />
<Setter Property=”Foreground” Value=”Green” />
</Style>

D.
<Style>
<Setter Property=”FontFamily” Value=”Verdana” />
<Setter Property=”Foreground” Value=”Green” />
</Style>



Leave a Reply 0

Your email address will not be published. Required fields are marked *