How to configure appellation starts as windows service automatically?

To configure an application to start as a Windows service automatically, you can follow these steps:

  1. Open the Command Prompt as an administrator.
  2. Navigate to the directory where the executable file of the application is located.
  3. Run the following command:
luaCopy codesc create ServiceName binPath= "C:\Path\To\Executable.exe"

Replace “ServiceName” with the name you want to give to the service and “C:\Path\To\Executable.exe” with the path to the executable file of your application.

  1. Once the service is created, you can start it with the following command:
sqlCopy codesc start ServiceName

Replace “ServiceName” with the name you gave to the service.

  1. To ensure that the service starts automatically when the computer starts, you can run the following command:
arduinoCopy codesc config ServiceName start= auto

This sets the startup type of the service to automatic.

Note: If you want to delete the service, you can run the following command:

arduinoCopy codesc delete ServiceName

Replace “ServiceName” with the name of the service you want to delete.

Or

Control whether an app can run in the background

  1. Select Start , then select Settings  > Apps > Apps & features.
  2. Scroll to the desired app, select More options on the right edge of the window, then select Advanced options.
  3. In the Background apps permissions section, under Let this app run in the background, select one of the following options:
    • Always—The app runs in the background, receiving info, sending notifications, and staying up-to-date even when you’re not actively using it. This option may use more power.
    • Power optimized—Windows decides what will save the most power while still allowing the app to receive notifications and update periodically. This option may limit an app that uses a lot of power.

Published by

Bob Lin

Bob Lin, Chicagotech-MVP, MCSE & CNE Data recovery, Windows OS Recovery, Networking, and Computer Troubleshooting on http://www.ChicagoTech.net How to Install and Configure Windows, VMware, Virtualization and Cisco on http://www.HowToNetworking.com