Try   HackMD

SOLVED! C# 1 Line synchronous your query!

tags: C#,tutorial

Table of Contents

1. POST

Ex:

string resstring = System.Threading.Tasks.Task.Run(() => httpClient.PostAsync(Setting.FHIRurl, new StringContent(jsonStr, Encoding.UTF8, "application/json"))).Result.Content.ReadAsStringAsync().Result;

Return:

restring = ""

1. GET

string resstring = System.Threading.Tasks.Task.Run(() => httpClient.PostAsync(Setting.FHIRurl, new StringContent(jsonStr, Encoding.UTF8, "application/json"))).Result.Content.ReadAsStringAsync().Result;