Hello,
I use a lot of xamNumericEditor controls, with always the same properties. e.g.
Is there a way to specifiey style or new control, with that properties and then always use that style or property? I don't want to specify these property for every control.
I already tried to create a style, but then all my DarkMetroTheme styles are lost on that control.
<Style x:Key="styleDecimalInput" TargetType="{x:Type igEditors:XamNumericEditor}"> <Setter Property="Mask" Value="{}{double:-9.4}"/> <Setter Property="PromptChar" Value=""/> <Setter Property="TrimFractionalZeros" Value="True"/> </Style>
Hello Markus,
Thank you for posting in our forums!
You should set the BasedOn property of your style to the MetroDark theme. Then your style can derive off of the MetroDark style and apply to all of the XamNumericEditors.
See below for a code snippet of how to achieve this.
<Window xmlns:igTheme="http://infragistics.com/Themes"> <Window.Resources> <Style TargetType="{x:Type igEditors:XamNumericEditor}" BasedOn="{x:Static igTheme:EditorsMetroDark.XamNumericEditor}"> ... </Style>
If you have any further questions or concerns with this, please let me know.
Sincerely,Michael H.Software DeveloperInfragistics, Inc.www.infragistics.com/support