Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

windows worker service

add the extension Microsoft.Extensions.Hosting.WindowsServices
in Program.cs write:

IHost host = Host.CreateDefaultBuilder(args)
    .ConfigureServices(services =>
    {
        services.AddHostedService<Worker>();
    })
    .UseWindowsService()
    .Build();

await host.RunAsync();
Comment

Worker service as Windows Service

sc create workertest binPath=c:codeworkerpubWorkerTest.exe
Comment

PREVIOUS NEXT
Code Example
Csharp :: .net form binding why cant i skip index 
Csharp :: connection string of bulk insert with csv in c# 
Csharp :: unity rotatoin angle 
Csharp :: C# is folder 
Csharp :: Razor do while loop 
Csharp :: c sharp while statement 
Csharp :: add integer to string c# 
Csharp :: check the request comes from which operating system used by user in asp net core 
Csharp :: entity framework where date between 
Csharp :: get first and last item list c# 
Csharp :: c# quaternion eular calculator 
Csharp :: Smooth Sentences c# 
Csharp :: How to compile just one file in c# 
Csharp :: get image information using c# 
Csharp :: unity transform.translate 
Csharp :: c# list with only unique items 
Csharp :: unity c# request store review 
Csharp :: linq where c# 
Csharp :: C# get the last item of the array 
Csharp :: get multi-selected rows gridcontrol devexpress 
Csharp :: wie macht man eine schleife in c# 
Csharp :: how to do Employing defensive code in the UI to ensure that the current frame is the most top level window in c# 
Html :: html pound symbol 
Html :: degree symbol html 
Html :: align center inner div using bootstrap 
Html :: bootstrap 5 overflow 
Html :: bootstrap col-md-5 center 
Html :: add favicon html 
Html :: html5 pattern for numbers only 
Html :: html display only on mobile 
ADD CONTENT
Topic
Content
Source link
Name
8+9 =