title: Change background color for selected ListBox item
body: <p>This is my XAML so far.</p>
  <pre class="lang-xml prettyprint-override"><code>&lt;ScrollViewer Grid.Column=&quot;1&quot; Grid.RowSpan=&quot;2&quot;&gt;
  
      &lt;ListBox   Background=&quot;Black&quot; ItemsSource=&quot;{Binding Path=ActiveLog}&quot; &gt;
          &lt;ListBox.ItemTemplate&gt;
              &lt;DataTemplate&gt;
                  &lt;Grid Background=&quot;Black&quot;&gt;
                      &lt;Grid.ColumnDefinitions&gt;
                          &lt;ColumnDefinition Width=&quot;200&quot;&gt;&lt;/ColumnDefinition&gt;
                          &lt;ColumnDefinition Width=&quot;*&quot;&gt;&lt;/ColumnDefinition&gt;
                      &lt;/Grid.ColumnDefinitions&gt;
                      &lt;Grid.RowDefinitions&gt;
                          &lt;RowDefinition&gt;&lt;/RowDefinition&gt;
                          &lt;RowDefinition&gt;&lt;/RowDefinition&gt;
                      &lt;/Grid.RowDefinitions&gt;
                      &lt;TextBlock Grid.Column=&quot;0&quot; Grid.Row=&quot;0&quot; Foreground=&quot;White&quot;&gt;
                          &lt;TextBlock &gt;Date:&lt;/TextBlock&gt;
                          &lt;TextBlock  Text=&quot;{Binding Path=LogDate}&quot;/&gt;
                      &lt;/TextBlock&gt;
                      &lt;TextBlock Grid.Column=&quot;1&quot; Grid.Row=&quot;0&quot; Foreground=&quot;White&quot;&gt;
                          &lt;TextBlock &gt;Severity:&lt;/TextBlock&gt;
                          &lt;TextBlock  Text=&quot;{Binding Path=Severity}&quot;/&gt;
                      &lt;/TextBlock&gt;
                      &lt;TextBlock Grid.Column=&quot;0&quot; Grid.ColumnSpan=&quot;2&quot; Grid.Row=&quot;1&quot; Foreground=&quot;LightGray&quot; Text=&quot;{Binding Path=Message}&quot;&gt;&lt;/TextBlock&gt;
                  &lt;/Grid&gt;
              &lt;/DataTemplate&gt;
          &lt;/ListBox.ItemTemplate&gt;
          &lt;ListBox.Template&gt;
              &lt;ControlTemplate&gt;
                  &lt;StackPanel Background=&quot;Black&quot; IsItemsHost=&quot;True&quot; &gt;
                  &lt;/StackPanel&gt;
              &lt;/ControlTemplate&gt;
          &lt;/ListBox.Template&gt;
  
      &lt;/ListBox&gt;
  &lt;/ScrollViewer&gt;
  </code></pre>
  <p>The only problem is that the selected item has a blue box to the right. I assume there is a way to change the selection color, but I can't find it.</p>