Hello..
I have a datagrid and one of the columns has a combobox inside a template. I really don't like the background color of the combobox but can't change it!!
Here is my code:
<!--Vehiculo Combobox--><DataGridTemplateColumn x:Name="vehiculoColumn" Header="Vehiculo" Width="100" SortMemberPath="VehiculoID" CanUserSort="True" ><DataGridTemplateColumn.CellTemplate><DataTemplate><ComboBox SelectedValue="{Binding VehiculoID,NotifyOnSourceUpdated=True, Mode=TwoWay,UpdateSourceTrigger=PropertyChanged, ValidatesOnExceptions=True}" SelectedValuePath="VehiculoID" DisplayMemberPath="VehiculoNombre" HorizontalAlignment="Stretch" ItemsSource="{Binding VehiculosCombo, ElementName=ListarDespachosPG}" Background="Blue" ><ComboBox.ItemContainerStyle><Style TargetType="{x:Type ComboBoxItem}"><Setter Property="Template"><Setter.Value><ControlTemplate><Grid><Grid.ColumnDefinitions><ColumnDefinition Width="50"/><ColumnDefinition Width="*"/><ColumnDefinition Width="*"/></Grid.ColumnDefinitions><TextBlock Margin="5" Grid.Column="0" Text="{Binding VehiculoID}"/><TextBlock Margin="5" Grid.Column="1" Text="{Binding VehiculoNombre}" /><TextBlock Margin="5" Grid.Column="2" Text="{Binding VehiculoPlaca}" /></Grid></ControlTemplate></Setter.Value></Setter></Style></ComboBox.ItemContainerStyle></ComboBox></DataTemplate></DataGridTemplateColumn.CellTemplate></DataGridTemplateColumn>
Guisselle