Sign in with Microsoft
Sign in or create an account.
Hello,
Select a different account.
You have multiple accounts
Choose the account you want to sign in with.

狀況

當您使用XMLSerializer來序列化System.Security.Authentication.SslProtocols型別值時,您會遇到 「 System.InvalidOperationException 」 錯誤。

原因

發生這個問題在.NET Framework 4.6.2 預覽中,加入一些成員 (SSL2,SSL3) ObsoleteAttribute的System.Security.Authentication.SslProtocols 列舉。因為XMLSerializer不支援ObsoleteAttribute,就會擲回和InvalidOperationException的錯誤。

解決方案

將移除System.Security.Authentication.SslProtocols的ObsoleteAttribute ,4.6.2 的.NET Framework 的未來版本中修正問題。

如需有關 Microsoft.NET Framework 4.6.2 預覽的詳細資訊,請參閱.NET Framework 4.6.2 預覽已知問題

更多的資訊

如需詳細資訊,請參閱在.NET Framework 4.6.2 中的應用程式相容性。

Need more help?

Want more options?

探索訂閱權益、瀏覽訓練課程、瞭解如何保護您的裝置等等。

社群可協助您詢問並回答問題、提供意見反應,以及聆聽來自具有豐富知識的專家意見。

Was this information helpful?

How satisfied are you with the translation quality?
What affected your experience?
By pressing submit, your feedback will be used to improve Microsoft products and services. Your IT admin will be able to collect this data. Privacy Statement.

Thank you for your feedback!

×