What is Dependency
Dependency means an object depending upon another object.
An object O1 depends upon another object O2 when O1 is using O2’s property to do some changes in its own(O1) property.
Why we need it
To achieve these changes, some notification logic is needed of-course. Before WPF or similar technology, we were doing it using event handlers.
Now, with WPF and similar technologies, we tell the underlying framework to do this for us. We tell underlying framework what we want ( using some syntax ) without bothering how ? And underlying framework does this for us.
Provisions provided by WPF
-
Binding using code/xaml.
-
DependencyProperty
-
Triggers
-
INotifyPropertyChanged interface
Learn about these, and slowly you will get the hold of it.
1
solved WPF Dependency guide [closed]