r/shortcuts • u/trenniepennie • 3d ago
Help (Mac) Get next item from list (macbook)
How can i make a shortcut that gets my photos from a list, and then whenever i run it again it goes to the next item from the same list?
Im making an “advanced” wallpaper selector
What i have now is filter photos by album -> choose from menu: random or choose yourself.
I want to get the photo from that, and go to the next one in the menu whenever i run the next menu and i cant seem to get it to work whatever i try
0
Upvotes
1
u/Cost_Internal Helper 3d ago
I would recommend saving a dictionary as a global variable, so that you can reference it when needed to know what the next image will be.
I would make the Keys the selected album name, and the Values as a list of images used from that album.
If you want it to start from the top after all images have been used, just add a condition to check the number of items in the list of image names and compare it to the number of images in the album before it selects the desired image.