How to use PropertyChangedCallBack

后端 未结 1 551
时光取名叫无心
时光取名叫无心 2020-12-11 00:36

I have a TextBox Binded to a dependancy property, I have implemented a PropertyChangedCallBack function, when the text changes I need to call textbox.ScrollToEnd() but I can

相关标签:
1条回答
  • 2020-12-11 01:05

    The DependencyObject is the object that raised the event. You need to cast obj to the type you need. E.g.

    TextBox textbox = (TextBox)obj;
    textbox.ScrollToEnd();
    
    0 讨论(0)
提交回复
热议问题