Hi --
You should be able to resolve your problem by moving your custom Style into the XamDataPresenter.Resources collection like so:
<igDP:XamDataPresenter x:Name="XamDataPresenter1" Theme="Office2K7Blue"> <igDP:XamDataPresenter.Resources> <Style TargetType="{x:Type igDP:DataRecordCellArea}"> <!-- Custom Style Here --> </Style> </igDP:XamDataPresenter.Resources></igDP:XamDataPresenter>
When you set the Theme property, behind the scenes Resources are being pumped in locally to the control's Resources collection, effectively overwriting your Style defined in UserControl.Resources. By moving your Style to the XamDataPresenter.Resources, your custom Style will overwrite the Styles included in the Theme.
Hope this solves your problem!
Hi Grant,
Thanks a lot for the help. It works. But there is another thing doesn't work as I expected.
What should I do in this case?
<Style TargetType="{x:Type igDP:DataRecordCellArea}">
<Style.Triggers>
<DataTrigger Binding="{Binding RelativeSource={RelativeSource Self}, Path=Record.DataItem.LineTestStatus, Converter={StaticResource lineActionStatusConverter}}" Value="True">
<Setter Property="Background" Value="{StaticResource RedBrush}" />
<Setter Property="FontWeight" Value="Bold" />
</DataTrigger>
</Style.Triggers>
</Style>
Thanks again.