下面這段代碼thows以下錯誤: System.Security.Cryptography.CryptographicException「句柄無效」DSACryptoServiceProvider構造函數會引發CryptographicException
CspParameters CSPParam = new System.Security.Cryptography.CspParameters(13, null, null);
CSPParam.Flags = CspProviderFlags.UseMachineKeyStore;
CSPParam.KeyContainerName = "MyKeys";
System.Security.Cryptography.DSACryptoServiceProvider r = new System.Security.Cryptography.DSACryptoServiceProvider(CSPParam); //Error occurs here
該代碼已經工作沒有問題,然後它開始拋出這個錯誤。我想不出任何我已經改變的與此有關的事情。 nayone有沒有看到這個錯誤?什麼嘗試的想法?
我看了那篇文章,並做了它說的,但它沒有幫助。 – HitLikeAHammer 2010-06-16 22:37:26