• 0

Run apps when laptop connected to mains


Question

I am looking for an app or method to have things run on my laptop when it is connected to the mains.

Does anyone know of any apps which can do this?

Alternatively can I run apps when connected to specific networks?

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

mains - you mean while plugged into power vs running on battery only?

As to while connected to specific network

Hmmm --- both should be possible with just the built in task scheduler -- just trigger them on an event. Now I don't believe there is event logged for change when plugged in or not plugged in, but it would be simple enough to monitor with a powershell script. Just do a google for monitor batterystatus powershell - simple Write-EventLog in your powershell script could be use to have an event happen when charging, when on battery. So your task could be setup to start your applications when on "mains" and then shut them down on "battery" only.

Same could be said for different events for when you are connected to a specific network, be it SSID based, IP based or some other check you could get from the eventlog, or create in the enventlog via powershell.

Link to comment
Share on other sites

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.