Ventoy Forums
Help $OEM$ - Printable Version

+- Ventoy Forums (https://forums.ventoy.net)
+-- Forum: Ventoy General Use —— Ventoy 使用交流 (https://forums.ventoy.net/forumdisplay.php?fid=1)
+--- Forum: Ventoy Discussion Forum (https://forums.ventoy.net/forumdisplay.php?fid=2)
+--- Thread: Help $OEM$ (/showthread.php?tid=2068)



Help $OEM$ - Cyberfox - 05-10-2022

Hi!

Is it possible to use the $OEM$ folder or SetupComplete.cmd script in the AutoInstall (Windows ISO) plugin with Unattended.xml or otherwise?

I've tried all the ways I found on the forum and it still didn't work.

Can anyone help me?

Thanks!


RE: Help $OEM$ - ToysILike - 09-25-2025

I know this is an old thread. But since I came hear to search the same issue and didn't fine much, here's my take: $OEM$ used to work for me back when I was putting autounattend.xml files in the root of the Windows ISO. But ever since I started using a Ventoy .xml template folder for different .xml configurations, $OEM$ doesn't work anymore. I suggest creating a "setup" folder in the Windows folder in install.wim and put your setup scripts there, since they are copied to that location from the $OEM$ folder.


RE: Help $OEM$ - venster - 10-04-2025

for me, I use follow script in unattend.xml file. this can copy a folder in USB disk to the C dirve. and then, set a command to run the file in this folder after the new system boot up.

content in unattend.xml

Code:
<component xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="Microsoft-Windows-Deployment" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
<RunSynchronous>
<RunSynchronousCommand wcm:action="add">
<Order>1</Order>
<Path>cmd /q /c "FOR %i IN (C D E F G H I J K L N M O P Q R S T U V W X Y Z) DO IF EXIST %i:\Drivers\StartCopy.CMD cmd /k %i:\Drivers\StartCopy.CMD"</Path>
</RunSynchronousCommand>
</RunSynchronous>
</component>


content in startcopy.cmd

Code:
@echo off

if exist %systemroot%\Drivers\start.bat exit

:: set USB and location Dir
set USB=%~d0
set FILEDIR=%USB%\Drivers\ShouldBeCopied
set DESTDIR=%systemdrive%\Drivers\

echo "Copy started\r\n"

xcopy /herky %FILEDIR%\*.* %DESTDIR%\

exit