Reputation: 229
Am using toggle switch of windows phone 8.1 (Don't want to use WPToolKit)
Am able to change the toggle switch color, when IsOn=true (ToggleSwitchCurtainBackgroundThemeBrush). But when the toggle switch is off, it is taking default background color. Is there any property to change the Toggle switch color when IsOn=false ?
Thanks, Snober
Upvotes: 0
Views: 208
Reputation: 346
Have you tried to modify the Template of your ToggleSwitch ? You should be able to modify the background of the toggle switch by adding a background color to the element "OuterBorder".
Upvotes: 0
Reputation: 1775
You could play with the RequestedTheme (Dark/ Light) or as a better option, change the style/ template.. Open in Blend > Right click on the item (ToggleSwitch) > Edit Template > Current .. then you can play with the template as you want :)
You can refer to this post for more: http://social.technet.microsoft.com/wiki/contents/articles/30199.make-a-styled-button-in-xaml-for-universal-windows-apps.aspx
(This post about Button control, but you can do it for any control)
Upvotes: 1