Skip to content
Prev Previous commit
Next Next commit
Update xml/System.ComponentModel.DataAnnotations/ValidationContext.xml
Co-Authored-By: Maira Wenzel <[email protected]>
  • Loading branch information
HongGit and mairaw authored Nov 23, 2019
commit 9571e9778d4089cdc32d099e8388e3d6528f4331
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@

This property represents an entity member name, not the name of a corresponding data field. Therefore, this name is not localized. It should be set only for property or parameter contexts.

In .NET Framework 4.7.2 and earlier versions, when using a custom <xref:System.ComponentModel.DataAnnotations.ValidationAttribute?displayProperty=nameWithType>, the `MemberName` property returns `null`. Starting with [.NET Framework October 2019 Preview of Quality Rollup](https://devblogs.microsoft.com/dotnet/net-framework-october-2019-preview-of-quality-rollup/) for .NET Framework 4.8, the property returns the member name if you add the following setting to your web config file:
In .NET Framework 4.7.2 and earlier versions, when using a custom <xref:System.ComponentModel.DataAnnotations.ValidationAttribute?displayProperty=nameWithType>, the `MemberName` property returns `null`. Starting with [.NET Framework October 2019 Preview of Quality Rollup](https://devblogs.microsoft.com/dotnet/net-framework-october-2019-preview-of-quality-rollup/) for .NET Framework 4.8, the property returns the member name if you add the following setting to your *web.config* file:

```xml
<configuration>
Expand Down