Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

httpclient

using System;
using System.Net.Http;

namespace ConsoleApplication
{
    public class Program
    {
        private static HttpClient Client = new HttpClient();
        public static async Task Main(string[] args) 
        {
            Console.WriteLine("Starting connections");
            for(int i = 0; i<10; i++)
            {
                var result = await Client.GetAsync("http://aspnetmonsters.com");
                Console.WriteLine(result.StatusCode);
            }
            Console.WriteLine("Connections done");
            Console.ReadLine();
        }
    }
}
Comment

PREVIOUS NEXT
Code Example
Csharp :: remove from list based on condition c# 
Csharp :: audio unity 
Csharp :: how to populate list in c# 
Csharp :: how to access asp button of gridview 
Csharp :: asp.net core authorization default policy 
Csharp :: c# array.reduce 
Csharp :: c# read xml tag value 
Csharp :: how to change color of part from the text in textblock wpf 
Csharp :: c# remove invalid directory characters 
Csharp :: push c# array 
Csharp :: run in new thread C# 
Csharp :: Match one of 1, 2, x or X, or nothing 
Csharp :: What are logic gates? 
Csharp :: linq c# object except two lists 
Csharp :: c# picturebox cursor hand 
Csharp :: store data between razor pages 
Csharp :: c# Case insensitive Contains(string) 
Csharp :: Merge two List using Linq 
Csharp :: demand a Security action c# 
Csharp :: oracle c# parameters wont work 
Csharp :: button event trigger wpf 
Csharp :: c# while true loop 
Csharp :: load information with txt file to uwp c# 
Csharp :: do while loop in c# 
Csharp :: c# read huge file 
Csharp :: c# if break 
Csharp :: instantiate date time variable C# 
Csharp :: c# string verbatim 
Csharp :: insert data to access database c# 
Csharp :: delete selected cells in Datagridview 
ADD CONTENT
Topic
Content
Source link
Name
7+8 =