xamarin.forms - Error with request headers add -


i working on xamarin forms app , want data webapi. when type request.headers.add got squiggy line on add message "webheadercollection not contain definition add accepting first argument of type webheadercollection found. missing using directive or assembly reference"

        httpwebrequest request = (httpwebrequest)webrequest.create(string.format(constants.lndefaultarticles, category));                     request.method = "get";                     request.accept = "application/json";                     request.headers.add("authorization", string.format("bearer {0}", accesstoken));   

how can resolve this?


Comments

Popular posts from this blog

neo4j - finding mutual friends in a cypher statement starting with three or more persons -

minify - Minimizing css files -

php - How to remove letter in front of the word laravel -