Jump to content

RunOnceEX is no longer executed


Recommended Posts

Good morning.
I am struggling with a strange RunOnceEx situation.
I have been using this procedure for years from W7 up to W11 22H2 and it works regularly on both HOST PC and virtual machine, but these days an unexplainable thing happens to me.
When I run this procedure on a newly built pc with Ryzen 9 7950X and still running W11 22H2, the RunOceEx does not run, when I try the same ISO with RunOnceEx on another PC or virtual machine it runs.
I have been going crazy for a few days and can't figure out why and don't know what solution to look for.
Any ideas?
This is the "setupcomplete.cmd" script that I have always uitilized.

Screenshot-003.png

-------------------------------------------------------------------------
@echo off
for %%w IN (D E F G H I J K L M N O P Q R S T U V W X Y Z) DO IF EXIST %%w:\sources\install.wim SET CDROM=%%w:

REG ADD HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx
SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx

REG ADD %KEY% /v Flags /t REG_DWORD /d "20" /f

REG ADD %KEY% /V Title /D "Post Installation..." /f  >NUl

REG ADD %KEY%\06 /VE /D "Calculator Legacy" /f  >NUL
REG ADD %KEY%\06 /V 1 /D "%CDROM%\Software\Calculator_Legacy_2.0.exe" /f  >NUL

REG ADD %KEY%\07 /VE /D "7-Zip 22.01" /f  >NUL
REG ADD %KEY%\07 /V 1 /D "%CDROM%\Software\7z2201.msi /quiet /norestart" /f  >NUL

EXIT

--------------------------------------------------------------------------------------------------

Sincerely thank you

Edited by DMD
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...