What's the difference between StaticResource and DynamicResource in WPF?

前端 未结 8 2138
长发绾君心
长发绾君心 2020-11-22 12:33

When using resources such as brushes, templates and styles in WPF, they can be specified either as StaticResources



        
8条回答
  •  旧时难觅i
    2020-11-22 13:24

    StaticResource will be resolved on object construction.
    DynamicResource will be evaluated and resolved every time control needs the resource.

提交回复
热议问题