Category : .net

Please explain below error and possible causes. Give me any work around to fix it. Running this script in Win2012 standard. Collect data locally:ExceptionThe SSL connection could not be established, see inner exception. at System.Net.Http.ConnectHelper.EstablishSslConnectionAsyncCore(Stream stream, SslClientAuthenticationOptions sslOptions, CancellationToken cancellationToken) at System.Net.Http.HttpConnectionPool.ConnectAsync(HttpRequestMessage request, Boolean allowHttp2, CancellationToken cancellationToken) at System.Net.Http.HttpConnectionPool.CreateHttp11ConnectionAsync(HttpRequestMessage request, CancellationToken cancellationToken) at System.Net.Http.HttpConnectionPool.GetHttpConnectionAsync(HttpRequestMessage request, ..

Read more

I’m looking for a solution to access the system media controls/status etc. I’m language agnostic, so long as I can run it from a node application (native module, executable to stdout, etc.) My ultimate goal is to access media status cross-platform, but I’ll settle for Windows to start as Linux and macOS probably have a ..

Read more

I added user32.dll in my windows forms c++ project like this: public ref class MyForm : public System::Windows::Forms::Form { public: [DllImportAttribute("user32.dll")] MyForm(void) { InitializeComponent(); } … }; and after running the project i faced with this problem: HResult=0x8013153A Message=Error: PInvoke item (field,method) must be Static. This exception is thrown here enter image description here what ..

Read more

SOS. I have 2 projects: "MainServer" and "CleanService" on .Net Core 3.1. Both Console Application output type. Post-Build MainServer copies the assembled CleanService.exe to its own folder in order to run it during operation. MainServer.csproj <Project Sdk="Microsoft.NET.Sdk.Worker"> <PropertyGroup> <TargetFramework>netcoreapp3.1</TargetFramework> <UserSecretsId>****</UserSecretsId> <Platforms>x86;x64</Platforms> </PropertyGroup> <ItemGroup> <PackageReference (…) /> </ItemGroup> <Target Name="PostBuild" AfterTargets="PostBuildEvent"> <Exec Command="xcopy /Y /i /s ..

Read more

I have this code shown below to read installed software on a specific device from the registry: private static List<string> ReadRemoteRegistryusingWMI(string machineName= "192.168.x.x") { List<string> programs = new List<string>(); ConnectionOptions connectionOptions = new ConnectionOptions(); connectionOptions.Username = @"****"; connectionOptions.Password = @"****"; //connectionOptions.Impersonation = ImpersonationLevel.Impersonate; ManagementScope scope = new ManagementScope("\" + machineName + "rootCIMV2", connectionOptions); scope.Connect(); string ..

Read more