Error Details are as follows:
Application:Myservice.exe
CoreCLR Version: 6.0.2123.36311
.NET Version: 6.0.21
Description: The process was terminated due to an unhandled exception.
Exception Info: System.PlatformNotSupportedException: ServiceController enables manipulating and accessing Windows services and it is not applicable for other operating systems.
at System.ServiceProcess.ServiceBase..ctor()
at Myservice..ctor() in C:\Dev\Visual Studio\MyServiceProcessor\Myservice.cs:line 17
at Myservice.Program.Main() in C:\Dev\Visual Studio\MyServiceProcessor\Myservice\Program.cs:line 22
We have installed System.ServiceProcess.ServiceController from nuget package in order to resolve the issue but no luck.