Wallpaper Changer App & Gadget
| | Like many of you, I’ve got galleries of photographs on my PC. I’d like my desktop background to rotate through them automatically as I go through my daily activities. Being too lazy to open control panel, change my background by hand, and then go back to work, I wrote an application and a Vista gadget to do the work for me. |
| Bill Wagner Difficulty: Easy Time Required: 1-3 hours Cost: Free Software: Hardware: |
The gadget is a fairly straightforward set of JavaScript that lets you pick a directory of photos, set a time interval between each change, and pause the wallpaper changer. The C# code works around a limitation or two in the Vista Gadget trust system. Vista gadgets can’t directly access .NET assemblies in the current gadget API. However, they can access COM objects, or they can start verifiably safe .NET executables. Vista Gadgets with that include COM objects require administrative privileges to install. Therefore, I chose the latter strategy. I wrote a small Windows Forms application that reads the command line, verifies it as an image, and changes the current wallpaper. The C# application’s main window is invisible on startup, and immediately exits after changing the wallpaper. Using this strategy, any regular user can install or update this gadget.
Comment Notification
If you would like to receive an email when updates are made to this post, please register here
Subscribe to this post's comments using