WPF Bind to parent property from within nested element using style

后端 未结 2 888
执念已碎
执念已碎 2020-12-10 03:42

I\'ve been trying to build a text box with a hint that\'s displaying while it\'s empty. I\'m having trouble setting the hint text from within a style.

To be precise

2条回答
  •  长情又很酷
    2020-12-10 04:10

    Reativesource doesn't work as expected. It is better to create watermark textbox using control template. But your version could work:

    
        
    
    
        
        
            
        
    
    

提交回复
热议问题