0

I am trying to programmatically change (using AHK) the wallpaper folder location (album) displayed in the Personalization > Background setting in Windows 10. I read here that the slideshow.ini file located at %APPDATA%\Microsoft\Windows\Themes contains the information for the location but it is "uuencoded in PCIDLIST_ABSOLUTE struct". I tried online uudecoding tools but they fail to decode. How can I go about doing this?

iamMG
  • 1
  • Can you post the encoded data? I tried to check my own slideshow.ini but it's empty – golimar Dec 02 '21 at 14:15
  • [Slideshow] ImagesRootPIDL=NGAFA8BUg/E0gouOpBhoYjAArADMdqDAuAI160KJpVKMFhZ4rKQ+BpHqmAQAAYCAv7bEAAAA9woQXP/tUHAtafAXoZx1BgK1kZnodcdAUAAYAEDAAAAAAQnU6GIEAcVYsxGchBXZyNHAAYEAJAABA8uv94ETHSnU6GoLAAAAE9MAAAAACAAAAAAAAAAAAAAAAAAAAQaceCwVAEGAsBAbAAHAhBAcAUGAyBwcAAAAaAQ3AEDAAAAAAYoUyAIEAIzSrAAOAkAAEAw7+mjUcUYiSNEiuAAAAQgrBAAAAQAAAAAAAAAAAAAAAAAAAAAbFXGAyAwSAsCAAAgEAMJAAAwJA8uvFCAAAEzUQN1td66/Nyx/DFIjECkOjOXLpBAAAQGAAAAAfAAAAwCAAAwdAkGAuBAZA8GA3BwcA4CApBQbA0GAlBgcAMHApBgdAUGAjBwbA4GA0BgcA8GAsBAcAEGAuBQZAwGAfBwYAcHA1AgbAEDAoBgMAQHA4BQeAUGA3BQeAAAAAAAAAAAAAAgEAAAA – iamMG Dec 04 '21 at 14:09
  • @golimar , these are the entire content of the file. – iamMG Dec 04 '21 at 14:15
  • That's not uuencoded but base64 encoded, and if you base64 decode that you get binary data. You probably need to copy that binary data into a PCIDLIST_ABSOLUTE variable in your program – golimar Dec 05 '21 at 05:21
  • @golimar in what format should I be decoding it into? UTF-8? Can you refer me to an online tool to do such a conversion? I tried www.base64decode.org but it doesn't seem to be working. – iamMG Dec 05 '21 at 08:37
  • Edit: I am so stupid. You've clearly written 'binary'. Anyway, I now have the binary data. How do I read it as text? For changing the folder location, I need to be able to edit it. – iamMG Dec 05 '21 at 08:53
  • I'm not sure if this can be done with AHK. With C language I would to that with fread (https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/fread?view=msvc-170). That would copy the binary data as-is to a memory buffer, where the Windows code would read and interpret it – golimar Dec 05 '21 at 11:00
  • Thanks, I'll look into it. – iamMG Dec 08 '21 at 16:30

0 Answers0