Hello experts! Please help me on creating custom control with multiple appearances, each appearance is complete different from others (each appearance combining of different components, not just slightly change of style).
I'm making a custom control called BudgetCircleControl, that display a circle and an arc, that present the current value with max value of budget. Let me describe what I currently have.
The code is so long that I put it in a github repository, please take a look:
https://github.com/bananaback/LearnHowToMakeCustomControl
I created BudgetCircleControl that implement Control, define my custom control style in BudgetCircleControl.xaml, it all in Components folder.
This works fine but when I want to have some improvements like when CurrentValue exceed MaxValue, don't show the circle anymore, show text and other things to warning. I tried to use VisualStateManager but it just good for slightly change in style in my opinion. In my case I need complex combination of components, completely different. I try to implement something like ControlTemplate, DataTemplate to dynamically switch template in code, I also try ControlTemplate Trigger but that didn't work and really messy so I think I shouldn't put it here. I need your help. Please show me how to achieve that please, create custom control with different appearances depend on some property. Thank you so much.