HKCU Registry Setting not applied

Aldebaran

New Member
Hi,

I recently bought the PRO version and testing the beta v1.9.0.7230 in combination with Windows 10 build 1909.
Importing registry entries doesn't bring me the expected results. My actions:

1) Added the wallpapers to the image
2) Importing the REG key into NTLite
3) Created an ISO
4) Installed the ISO on a VM

The installation completed succesfully but the expected registry key is not present.
Is this a bug or do I miss something?

Thanks in advance for your help and advice.
 

Attachments

  • log.txt
    1.4 KB
  • Wallpaper01.PNG
    Wallpaper01.PNG
    59.7 KB
  • Wallpaper02.PNG
    Wallpaper02.PNG
    29 KB
  • Wallpaper03.PNG
    Wallpaper03.PNG
    192.8 KB
Was the wallpaper file was placed to the correct location?

Yes definitely. The wallpaper is set if I import the same regkey manually into the VM. And the regkey should be set even if the wallpaper image wasn't injected correctly. Those 2 actions (importing the image / importing a regkey) aren't related to each other). You'll get a black screen if the wallpaper is not availlable.
 
Last edited:
Tested the registry import feature with NTLite v1.8.0.7230 x64 (non beta). Same result. Registry key is not changed after installing a fresh VM.
Next thing I'm going to try is using the older Windows 10 build 1903 x64 version.
 
That reg key should be saved to the Administrator or System account by default (HKEY_CURRENT_USER).

Probably you can find it in one of these:
HKEY_USERS\S-1-5-19\Control Panel\Desktop
HKEY_USERS\S-1-5-20\Control Panel\Desktop

An update to the tool by nuhi should fix it.
 
I've tested Windows 10 build 1903 i.c.w. NTLite v1.8.0.7230 x64 and the registry import feature. It's still is not working as expected for me.
However, the first thing I tested was the default user profile. So I loaded the NTUSER.DAT into the registry via a
reg load HKU\temphive c:\users\default\ntuser.dat

Wallpaper04.PNG


The correct value is present but apparently a newly created user doesn't use the default profile. I created several different accounts but none of them was working with the correct backgroud. HKLM registry keys are working fine.
 
That reg key should be saved to the Administrator or System account by default (HKEY_CURRENT_USER).

Probably you can find it in one of these:
HKEY_USERS\S-1-5-19\Control Panel\Desktop
HKEY_USERS\S-1-5-20\Control Panel\Desktop

An update to the tool by nuhi should fix it.

I don't think this is the solution. There should be an explanation why the default user profile has been changed, but not used.
 
Last edited:
Hi,

for HKCU, simply use a REG file with HKCU, not HKEY_USERS\S-1-5-19.
When NTLite detects HKCU, it uses Default User hive. If Windows is ovewriting the wallpaper registry entry on user creation, then you would need a reg add command to overwrite it on user logon (hkcu runonce key).

Best would be to attach the reg you're adding and let me know what to check for.
If it's integrated on the image (check the integrate - registry - hive on the right, press Edit), then the runonce method is the way.

Thanks.
 
Hi,

for HKCU, simply use a REG file with HKCU, not HKEY_USERS\S-1-5-19.
When NTLite detects HKCU, it uses Default User hive. If Windows is ovewriting the wallpaper registry entry on user creation, then you would need a reg add command to overwrite it on user logon (hkcu runonce key).

Best would be to attach the reg you're adding and let me know what to check for.
If it's integrated on the image (check the integrate - registry - hive on the right, press Edit), then the runonce method is the way.

Thanks.

Hi,

Thanks for the quick response. My issue with the 'Run Once' method is that you'll need to reboot (or logoff / logon) to activate the configured background.
I was hoping that pre-configuring the default user would fix this issue. I have attached the reg file that I'm using.
I import the REG file in NTLite, create an ISO and use the ISO to install a VM. The first user created, should have the reg value (regardless of the wallpaper being present or not. In my case the created user does not have the proper value in the registry.......despite the fact that the correct value is available in the default user's NTUSER.DAT.
 

Attachments

  • Wallpaper.reg
    292 bytes
Last edited:
Since I haven't done this yet, here are some top of the head suggestions:
- Try X: like the original, instead of C: for the wallpaper path
X:\Windows\Web\Wallpaper\Windows\img020.jpg

- You can replace the default C:\Windows\Web\Wallpaper\Windows\img0.jpg on the image with any image:
(1920 x 1200 pixels, 96 dpi, 24 bit)
There are higher res versions as well, different filename.
But sfc scan might replace it back.

- This is a stretch, the old Win7 tweak:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes]
DesktopBackground
REG_EXPAND_SZ
C:\Windows\Web\Wallpaper\Windows\img020.jpg

- There are policies to lock it, but that's not good

Let me know if you find an easy way, I might take a shot at this soon, got it requested many times, didn't understand what's the fuss about.
But seems MS made it difficult in order to require Windows activation for changing the background (Personalize), which is fine, just a bit annoying.
 
Does anyone knows how to change wallpaper and lockscreen with cmd commands?
i find out a method (which nuhi talked about) but it locks down settings so it is not good option to use.





edit:1 this changes wallpaper on next restart

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Control Panel\Desktop]
"WallPaper"="c:\\windows\\oem\\wallpaper.png"






but i cant find any solution for lockscreen on normal editions rather than enterprise
 
Last edited:
I have it done the easy way:
Replace the default wallpaper.

To keep fixed the wallpaper and icons NoSaveSettings=1 in the windows registry do the job (after setting all up).

I recently bought the PRO version and testing the beta v1.9.0.7230 in combination with Windows 10 build 1909.
Importing registry entries doesn't bring me the expected results.

The installation completed succesfully but the expected registry key is not present.
Is this a bug or do I miss something?

You didn't answer my question but most probably you are missing something:
Themes change the wallpaper on first logon if isn't removed.
Edit the theme file, not the registry.
I have edited some theme files with notepad to make the desktop wallpaper a slideshow.
- You can replace the default C:\Windows\Web\Wallpaper\Windows\img0.jpg on the image with any image:

But sfc scan might replace it back.

I have replaced the default background wallpaper in Windows\web\* and also in Windows\winsxs\*.
 
hi kasual thx for answer did u find any solution for changing lockscreen?
I had used the $OEM$ location but if you want to make sure that no sfc scannow will remove it, replace the files in winsxs or remove the files with NTLite and using the $OEM$ location the lockscreen won't be removed because there won't be "safe" lockscreen wallpapers to restore.
 
Wallpaper:

Code:
POWERCFG -H OFF >NUL 2>&1
PowerShell.exe -NoProfile -ExecutionPolicy Bypass -File "%WINDIR%\Setup\Scripts\wallpaper.ps1"
DEL /F /Q "%WINDIR%\Setup\Scripts\wallpaper.ps1" >NUL 2>&1

change -- wallpaper.txt to -- wallpaper.ps1

Lockscreen:

Code:
POWERCFG -H OFF >NUL 2>&1
PowerShell.exe -NoProfile -ExecutionPolicy Bypass -File "%WINDIR%\Setup\Scripts\lockscreen.ps1"
DEL /F /Q "%WINDIR%\Setup\Scripts\lockscreen.ps1" >NUL 2>&1

change -- lockscreen.txt to -- lockscreen.ps1

the code I gave you put in setupcomplate or wherever you want in your scripts ...
 

Attachments

  • wallpaper.txt
    263 bytes
  • lockscreen.txt
    1.3 KB
Back
Top