Skip this background info to get straight to the point Okay here's the deal; I recently rediscovered Mission Control and created different environments for my very different types of work. The background plays an important role for setting the right mood. Assigning apps to work in certain environments only seemed like a good idea at first, but it didn't work nearly as smoothly as I'd hoped – sometimes the apps kept bouncing to places I didn't mean them to go to, and all the jumping made my concentration and the computer's CPU drain. Back to the start. Maybe I'll just handle app and file organizing by using tiny concentration apps, they're great. But, the desktop issue. I'm fairly new to applescript and automating. I've managed to customize and make a few scripted items for my frequent use, but I can't seem to find a tutorial that's similar enough so I could figure this one out. Currently I have 7 special work environments that are mandatory to be kept separate. The amount might change by a few, +-. I have a "Mode wallpapers" folder that contains folders that are named after each environment. Those folders contain multiple desktop pictures each. What I'd want an easily accessible script to do is to allow me to pick an environment, and it would set the desktop wallpaper by picking a random image in the corresponding environment wallpaper folder. Having to open Preferences > Desktop&Screensaver > Specify wallpaper folder, is a workflow killer. Getting a random wallpaper each time promotes creativity and fresh thinking. I found some tutorials but they were too different for me to figure out how to edit for getting what I want to do. For example, this one gave me a nice idea about a chance to have a dialog box with buttons I didn't even know about: http://hints.macworld.com/article.php?story=20090505222800665 How cool, but when I tried to change the number 3 to 7, the script informed me that I could only have a maximum of 3 buttons. Okay, I could compromise and live with grouping similar environments to threes and making a separate script for each group. But then I couldn't figure out how to change the code to not choose a static specified file, but a random file in a folder. Then I came across this one: https://github.com/pipwerks/OS-X-Wallpaper-Changer Okay cool, it's set to choose random images in a folder instead of specified ones. Also, it uses separate folders to fetch the files from, and there are several options. But the code regarding multiple display handling (which I don't need) was overwhelming, as well as the stuff about changing the wallpaper according to time. I was trying to customize my script by modifying parts of these but because I don't have much experience with code language and search engines only brought somewhat similar reference articles, I'm out of ideas. Any help, please?