Topic | Value |
---|---|
Id | WPF0014 |
Severity | Error |
Enabled | True |
Category | WpfAnalyzers.DependencyProperty |
Code | SetValueAnalyzer |
Use a type that matches registered type when setting the value of a DependencyProperty
When setting the value of adependency property the value must be a representation preserving conversion due to the value being boxed.
Use a value of the registered type.
Configure the severity per project, for more info see MSDN.
#pragma warning disable WPF0014 // SetValue must use registered type.
Code violating the rule here
#pragma warning restore WPF0014 // SetValue must use registered type.
Or put this at the top of the file to disable all instances.
#pragma warning disable WPF0014 // SetValue must use registered type.
[System.Diagnostics.CodeAnalysis.SuppressMessage("WpfAnalyzers.DependencyProperty",
"WPF0014:SetValue must use registered type.",
Justification = "Reason...")]