'RestSharp is missing Execute function?
I am trying to use RestSharp (my first time). I am using their example:
var client = new RestClient( "http://example.com" );
var request = new RestRequest( "AddressJSON", Method.GET );
request.AddParameter( "name1", 123 );
request.AddParameter( "name2", 456 );
request.AddParameter( "username", "abc" );
// execute the request
RestResponse response = client.Execute(request);
var content = response.Content; // raw content as string
However the function client.Execute() is missing from the library?!
I am using version 105.0.1.0 of the RestSharp from NUGET.
http://www.nuget.org/packages/RestSharp
Thanks
Solution 1:[1]
I had the same problem, with the line "var response = client.Execute(request);" the error is the same... the version of the Nugget is 107.xx, and it only allows me 'ExecuteAsync', so I uninstalled the RestSharp Nugget and reinstalled it but in its version 106.0.x, where the problem disappeared, and Execute works perfectly!!
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Dharman |
