Yubico Forum https://forum.yubico.com/ |
|
OTP C# Error Cannot implicitly convert type https://forum.yubico.com/viewtopic.php?f=3&t=1898 |
Page 1 of 1 |
Author: | paulw [ Wed May 27, 2015 2:58 pm ] |
Post subject: | OTP C# Error Cannot implicitly convert type |
I am trying to use the c# libraries on an ASP.NET webform and using the sample code of YubicoClient client = new YubicoClient(clientId, apiKey); YubicoResponse response = client.Verify(otp); I get the following error Error 1 Cannot implicitly convert type 'YubicoDotNetClient.IYubicoResponse' to 'YubicoDotNetClient.YubicoResponse'. An explicit conversion exists (are you missing a cast?) |
Author: | henrik [ Wed May 27, 2015 3:21 pm ] |
Post subject: | Re: OTP C# Error Cannot implicitly convert type |
Seems like the example in the documentation has a typo. Try this instead: Code: IYubicoResponse response = client.Verify(otp);
|
Author: | paulw [ Wed May 27, 2015 3:34 pm ] |
Post subject: | Re: OTP C# Error Cannot implicitly convert type |
Thanks so much, that worked. |
Page 1 of 1 | All times are UTC + 1 hour |
Powered by phpBB® Forum Software © phpBB Group https://www.phpbb.com/ |