c# - Setting an alias on the .net Portable Subset library -


i'm using nuget package microsoft.net.http add httpclient pcl domain library.

i want set custom network credential, can't because of error:

code :

httpclienthandler handler = new httpclienthandler(); icredentials credentials = new networkcredential("username", "password", "domain"); handler.credentials = credentials; _client = new httpclient(handler); 

error :

error 5 cannot implicitly convert type 'system.net.icredentials [c:\program files (x86)\reference assemblies\microsoft\framework.netportable\v4.5\profile\profile78\system.net.primitives.dll]' 'system.net.icredentials' c:[truncated]\apiclient.cs 26 35 deltekapi

the issue networkcredentials i'm providing implement nuget added implementation of icredentials, , interface httpclient wants pcl .net portable subset version.

can't think of way of fixing this?

this sounds bug had if install vs 2012 update 2 after wp8 sdk. run repair on vs update 2 installation fix it. see issue 2 in this kb article more information.


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

CSS3 Transition to highlight new elements created in JQuery -