WPF Change a label's display based upon a bound textbox contents change
I have a bound textbox and I need to change its associated display label to bold upon the presence of any content. I dont want to use javascript if at all possible.
T开发者_如何学运维hanks
Why would javascript be involved?
Anyway, if this is really wpf, bind the FontWeight property of your label to the textbox's text property, using custom converter that converts null/empty strings to Normal font weight, and non-null/non-empty to Bold.
精彩评论