Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9265843
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T14:10:37+00:00 2026-06-18T14:10:37+00:00

i have problem with styling the combobox’s togglebutton. my combobox xaml code looks like

  • 0

i have problem with styling the combobox’s togglebutton.
my combobox xaml code looks like this:

<ComboBox Width="Auto"
      HorizontalContentAlignment="Stretch"
      FontFamily="HelveticaNeue-Bold"
      FontSize="20"
      FontWeight="Bold"
      Foreground="#FFC0C0C0"
      Padding="0,0,0,0"
      Style="{DynamicResource navigationComboBox}"
      ItemsSource="{Binding Tournaments}"
      SelectedValue="{Binding SelectedTournament}">
<ComboBox.Resources>
    <SolidColorBrush x:Key="{x:Static SystemColors.HighlightBrushKey}" Color="Transparent" />
</ComboBox.Resources>
<ComboBox.ItemsPanel>
    <ItemsPanelTemplate>
        <WrapPanel IsItemsHost="True" 
                    Orientation="Vertical" 
                    Width="auto"
                    Height="{Binding Tournaments, Converter={StaticResource CollectionToHeightConverter}}"/>
    </ItemsPanelTemplate>
</ComboBox.ItemsPanel>
<ComboBox.ItemTemplate>
    <DataTemplate>
        <DockPanel x:Name="comboDock">
            <DockPanel.Background>
                <ImageBrush ImageSource="{Binding Converter={StaticResource ImagePathConverter}, ConverterParameter=comboboxitem-line.png}" />
            </DockPanel.Background>
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition Height="50" />
                </Grid.RowDefinitions>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="41" />
                    <ColumnDefinition Width="*" />
                </Grid.ColumnDefinitions>
                <DockPanel x:Name="comboArrow"
                            Grid.Column="0"
                            Visibility="Collapsed">
                    <DockPanel.Background>
                        <ImageBrush ImageSource="{Binding Converter={StaticResource ImagePathConverter}, ConverterParameter=SportsSubMenuActive.png}" />
                    </DockPanel.Background>
                </DockPanel>
                <TextBlock x:Name="comboText"
                            Grid.Column="1"
                            FontFamily="HelveticaNeue-Bold"
                            FontSize="20"
                            FontWeight="Bold"
                            Foreground="#FFC0C0C0"
                            Padding="0,0,10,0"
                            Text="{Binding Path=Name}"
                            TextAlignment="Left"
                            TextWrapping="Wrap" />
            </Grid>
        </DockPanel>
        <DataTemplate.Triggers>
            <DataTrigger Binding="{Binding IsSelected, RelativeSource={RelativeSource AncestorType=ComboBoxItem}}" Value="True">
                <Setter TargetName="comboArrow" Property="Visibility" Value="Visible" />
                <Setter TargetName="comboText" Property="Foreground" Value="#F94B01" />
            </DataTrigger>
        </DataTemplate.Triggers>
    </DataTemplate>
</ComboBox.ItemTemplate>

so i’m trying to remove the background set to on togglebutton, but it is not possible. if i remove the background on itemtemplate, then i can style the toggle button background. is there any special order in the process to prevent me from changing the background of the togglebutton content if it is set in itemtemplate?

thanks in advance guys,
Kristo

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T14:10:38+00:00Added an answer on June 18, 2026 at 2:10 pm

    Setting a property directly takes priority over any Setter(s). Instead of setting the property directly, use a Style for your DockPanel and use a Setter to set the background similar to what you do in your DataTrigger. That should allow you to change the background property elsewhere.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a problem regarding CSS styling for my list. Here is the code.
I have a problem styling/templating an AccordionItem in the accordion control from the silverlight
I have problem with my query on C, I’m using the oci8 driver. This
I have a problem with styling legend items in Highcharts , when applying a
I have a problem with asp:button styling. I added following style: .myAspButton { background-image:
I have a set of anchors like <a class=lb href=#>text</a> <a class=lb href=# style=width:200px>text</a>
i have this html and css code: <div class=header> </div> .header { top:0; left:0;
ok imagine that we have text like this String s=123 45678 91011122314 1516; now
I have a problem styling my form. Everything works fine except the checkboxes. They
I have a styling problem, I am using WordPress and want to do have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.