Xaml TextBox Text binding code make it common

1 posts, 0 answers
  1. dotnetavalanche
    dotnetavalanche avatar
    1 posts
    Member since:
    May 2011

    Posted 04 Jun Link to this post

    We have big WPF application with multiple screen. Each screen have multiple textboxes.

    We have used MVVM pattern so textboxes are bound to VM using like:
    {Binding Name,Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}

    In Most of the textboxes BUT not all, we want to set Delay Property to some value say 500 like:

    {Binding Name,Delay=500,Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}

    Rather than setting this on each textbox xaml line is there some shorter way to handle this?

    something like Style.xaml etc?
    These changes are applicable for most of the textboxes but not all....
Back to Top