I'd like to have a different desktop background depending on which network I'm attached to. Home, Work, Roaming, etc.
Does anyone know of a utility that can do this?
|
I'd like to have a different desktop background depending on which network I'm attached to. Home, Work, Roaming, etc. Does anyone know of a utility that can do this? | |||||
feedback
|
|
You don't specify your OS, so I'm assuming Windows. I have a script, knocked together in VBSctipt, that runs regularly (via Windows' built-in scheduled task feature) and changes my wallpaper to a random selection depending on time of day (so it picks one from the "morning" set between 0700 and 1000 and so on). Once it has decided the image to use, the following lines update the wallpaper:
You could create something similar that bases its choice purely on the IP range you appear to be on. You could detect your current public address by making a HTTP call to something like http://whatismyipaddress.com/ using the WinHTTP library (though if you use a public service like this, make sure you don't do the lookup too often). As an alternative to detecting your public IP address, you could try scan the output of You might get more help on this over on StackOverflow. | |||||||
feedback
|
|
Check out this SU thread. That might work for you. | ||||
|
feedback
|
|
You could create a script that checks your IP address and then changes your background. Too bad my scripting experience is so low, I would have no idea how to write this. Here's a VBscript to find your IP Address:
Now I need a smart programmer to add something to make it change your background, when the IP has a certain range/value. | |||||||||||
feedback
|
|
Just a point in [possibly] the right direction. Someone can post a new answer with the actual solution or edit this one if they choose to. From what I gather you're going to want to go by IP. At home you'll have an IP address that isn't the same as the one in work. So the first thing you'll need to do is find out what the current IP is. I found this batch script to do just that.
Now that you've got the IP address, you'll probably need to set up an if statement of sorts. The action of the if's will be something like the following
The downside of running this as a batch file is it will have to be set up as a scheduled task or something similar | ||||
|
feedback
|