c# - Where's the wallpaper registry key in Windows 8? -


i'm working on tool needs current user's wallpaper path.

on windows 7, can reading

hkey_current_user\software\microsoft\internet explorer\desktop\general\wallpapersource.

on windows 8 installation, key has value

c:\users\peter\appdata\roaming\microsoft\windows photo viewer\windows photo viewer wallpaper.jpg

which not wallpaper that's set.

is there other key can rely on?

the key mentioning isn't correct one. sounds me you've placed image desktop background internet explorer, , key opened register it.

the correct key desktop background location is: confirmed on: xp, ce, vista, 7, 8

hkey_current_user\control panel\desktop\wallpaper 

details:

  • main key: hkey_current_user
  • sub key: control panel\desktop
  • value name: wallpaper
  • value type: reg_sz
  • value data: full path image being used desktop background

also, under hkey_current_user\control panel\desktop\ find other wallpaper related options apply different styles: center, tile, , stretch.

hkey_current_user\control panel\desktop\wallpaperstyle hkey_current_user\control panel\desktop\tilewallpaper 

in order apply styles use following guide:

  1. center

    wallpaperstyle = 0 tilewallpaper = 0 
  2. tile

    wallpaperstyle = 0 tilewallpaper = 1 
  3. stretch

    wallpaperstyle = 2 tilewallpaper = 0 

Comments

Popular posts from this blog

c# - SVN Error : "svnadmin: E205000: Too many arguments" -

c# - Copy ObservableCollection to another ObservableCollection -

All overlapping substrings matching a java regex -