Guest User

Untitled

a guest
Mar 19th, 2018
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. public static async Task<dynamic> getDataFromService(string pQueryString)
  2. {
  3. HttpClient client = new HttpClient();
  4. var response = await client.GetAsync(pQueryString);
  5.  
  6. dynamic data = null;
  7. if (response != null)
  8. {
  9. string json = response.Content.ReadAsStringAsync().Result;
  10. data = JsonConvert.DeserializeObject(json);
  11. }
  12.  
  13. return data;
  14. }
Add Comment
Please, Sign In to add comment