P/invoke CreateProcessWithLogonW causes Error 1058: The service cannot be started, either because it is disabled or because it has no enabled devices associated with it.

If you're running the CreateProcessWithLogonW Win32 API command with P/invoke you may receive the following error

Error 1058: The service cannot be started, either because it is disabled or because it has no enabled devices associated with it.
 
This can occur if the "Secondary Logon" (seclogon) service is disabled in the services control panel. 


Comments

Popular posts from this blog

Windows Server 2016, 2019, 2022, Windows 10 and Windows 11: Date and time "Some settings are managed by your organization".

TFTPD32 or TFTPD64 reports Bind error 10013 An attempt was made to access a socket in a way forbidden by its access permissions.

Windows Server 2019 desktop icons such as My Computer, Windows cannot access the specified device, path, or file.