Hello everyone! Welcome to my first instructable. In this instructable I will show you how to make a program that changes your computer’s desktop to the most recent NASA Image of the Day. These images are always stunning and the program really adds to your desktop appearance.
The NASA Image of the Day is a wonderful source of images from Earth, inside NASA, and all the way out to distant galaxies. The images are always full of color, and I have yet to see one that does not go perfectly on a 1080p or less display.
This instructable contains directions for Windows 10 and the files included should mostly be usable for other similar operating systems, but it does require Java.
All files are available, open-source, on my GitHub.
I hope you enjoy and learn a lot from my first instructable. If you have any advice for me, I’d love to hear it!
Step 1: Set Up the Startup Files
Begin by opening your startup folder. Items in this folder will automatically run when you log in. If you won't be turning off your computer often, then you can skip this step and see how to manually schedule the program to run later on in Step 5.
To enter the startup folder, open the run dialog by tying [Windows Key] + R. In the run window that opens, type “shell:startup” without quotes (first image above) then hit enter.
Now you can download and move the attached file “DesktopChanger.bat” into startup. This file is programmed to run a .jar file from a folder on your desktop, so once you’ve moved it there, you should right-click the file and click on “Edit” in the menu.
You should now see a Notepad window open with some lines of code. You will need to change the line:
cd “[FOLDER LOCATION]” <br>
(WITH quotes) to include the location of your photo, instead of the placeholder. For example, if you placed the image on a folder in your C drive, you would instead type:
cd “C:/[FOLDER LOCATION]”
(WITH quotes.) If the item is located on a separate drive, include /d at the end of your quoted location, for example:
cd “D:\[FOLDER LOCATION]” /d
(WITH quotes.) You should use an empty folder that already exists, but without any images.
Step 2: Setting Up the Java Jar File
Now we’ll work on the folder you used earlier. If you have not already, then create the folder.
In this folder, you’ll want to include the attached file “Refresh Image.jar,” which is the main code that drives this program. You can find the source code on my github page. Make sure that the [FOLDER LOCATION] specified in the previous step is the exact folder location of the file. You can get the exact location of the file by right-clicking it in Windows Explorer and selecting "Properties," then copying the text listed beside "Location" (as in the images above.)
Now try running the Java file by double-clicking it. If you have Java properly installed, it should run without errors, and two new files named “img.jpg” and “img2.jpg” should pop up. Running it again should keep both files.
Step 3: Change Settings
Now that the files are set up, the only thing left to do is apply the settings. Go to your desktop, right-click, and select “Personalize.” This should open your settings. On Windows 8-10 this will open the Settings window (imaged above,) but on Windows 7 it should open the Control Panel.
Within the settings, you need to change a few options:
- Under the “Background” option, set the drop-down box to “Slideshow.”
- Under the “Choose a Fit” menu, I selected Span, since I find that is looks the best (it will resize the image so that it is cut off at the sides, so the photo will be cut down, but there won’t be any black bars or stretching of the image.
- And you’ll need to select the folder you created which contains “Refresh Image.jar” using the “Browse” button under the “Choose albums for your slideshow” section.
Note: In Windows 7 it seems you will need to select a set of photos; you can simply select the two images "img.jpg" and "img2.jpg" after running the "Refresh Image v1.2.jar" file.
Step 4: Registry Settings
NOTE: The Windows registry is where settings, software information, and other data is saved, and it is a very important part of your computer. Using the registry improperly can ruin your computer and render it unusable. But, if you follow these directions carefully enough, you will likely not have any issues at all.
If you aren’t comfortable with modifying registry values, then you can change the setting under “Change picture every” to 1 Minute. This will work too, but it will be much slower to change your desktop to the new photo when you start up your PC.
Open the registry by pressing [Windows Key] + R to open the run dialog, then type “regedit” (without quotes) and press enter. You will need to allow regedit to make changes to your computer (press “Yes” if you are prompted.) You now should see a window that, in the top left, looks like the first image included in this step. Navigate to HKEY_CURRENT_USER > Control Panel > Personalization > Desktop Slideshow, then double click the REG_DWORD labeled “Interval” (without quotes) click the “Decimal” radio button if it is not already selected. The “Value data” should NOT contain letters when in Decimal mode. Change the value to “1000” (now more than ever; WITHOUT quotes!)
Step 5: Scheduling Events
If you don’t want to turn your computer off often, you can use the Windows Task Scheduler. If you choose to do this, try the following:
1.) Open the run dialog and type “Taskschd.msc.”
2.) In the Actions pane to the right of the Task Scheduler window, click on “Create Basic Task…”
3.) Give your new task a name and, if you want, a description.
4.) After clicking next, select daily, click next, choose the time you want the photo refresh to be executed, then click next.
5.) In this section, select the radio “Start a program,” then click next.
6.) Now, either manually enter the location of the “Refresh Image.jar” file, or use browse to find it.
Click next, then Finish.
Step 6: Done!
That's it! You should try restarting your computer next time the photo is updated, and waiting to make sure that the desktop changes within whatever time was previously set for the slideshow interval.
I hope you liked this instructable, and I hope everything in it works. I may not be able to help with some problems related to setting this up, but if I can, I'd be glad to help. Please give me advice on this (my first) instructable. Thanks for reading through, and have a nice day!