How to use the "CodePagesEncodingProvider" Class at .NET core 2.1?
I want to use the code page (e.g. code page 936) which is not supported in UWP apps. I can get the code page 936 by use the "CodePagesEncodingProvider" class at .NET core 2.0, but it seems that there is not available at .NET core 2.1, how to fix this? Best regards.
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
- ID: a5c26a9c-9378-f153-0e10-2d893d8ea178
- Version Independent ID: 5a122d68-cd0b-abe8-fd6c-258d44c816a2
- Content: CodePagesEncodingProvider Class (System.Text)
- Content Source: xml/System.Text/CodePagesEncodingProvider.xml
- Product: dotnet-api
- GitHub Login: @rpetrusha
- Microsoft Alias: ronpet
CodePagesEncodingProvider works for me in a .Net Core 2.1 console application the same as in a .Net Core 2.0 console application, after I install the System.Text.Encoding.CodePages package from NuGet. Is that not the same for UWP?
Though I think the current documentation is not great and I have opened a separate issue about that: https://github.com/dotnet/docs/issues/7086.
Hi @svick , CodePagesEncodingProvider works for me too now, but I don't know how to conform the version of the .NET Core which I use now. I got message on the CodePagesEncodingProvider class websit: "The requested page is not available for .NET Core 2.1. You have been redirected to the newest product version this page is available for." I am afraid that the CodePagesEncodingProvider class can't be use in future, as this class is important for me. Thank you for the new open issus #7086 !
For Azure Function 2.0 with .NET Standard 2.0 I needed the same NuGet package which is not obvious from the current doc.