Skip to content

OSD\_SetOEMWallpaper

VB Scripting Library > OSD Scripting Library > OSD functions (OSD)

Changes the default Windows login wallpaper to one specified by the customer.

No arguments provided.

Boolean, TRUE if function completed successfully.

The wallpaper file to be used must allready exist on the disk in the following locations.

OPERATING SYSTEMFILE NAMELOCATION
Windows 8, 8.1, 10, Windows Server 2012 / 2012 R2,backgroundDefault.jpg<target drive>:\Windows\System32\oobe\info\backgrounds\
Windows 7, Windows Server 2008 / 2008R2backgroundDefault.jpg<target drive>:\Windows\System32\oobe\info\backgrounds\
Windows XP, Windows Server 2003 / 2003R2InstallationWallpaper.bmp<target drive>:\Windows\System32\

Typpically used in the PreBootScript.wsf
The wallpaper files can be placed on the filesystem using the OSD extra files feature, which allows for adding aditional files to the filesystem once the image has been applied.

The following example specifies that a custom wallpaper should be used.

Private Function IncludeScript(sScriptFile)
'...
End Function
'Begin
bStatus=True
If bStatus Then bStatus=IncludeScript("customlib.cis")
If bStatus Then bStatus=IncludeLibrary("Capalib.cin")
If bStatus Then bStatus=IncludeLibrary("Osdlib.cin")
If bStatus Then bStatus=Job_Start("WS","Script Name","1.0","ScriptName.log","INSTALL")
If bStatus Then bStatus=OSD_Initialize()
If bStatus Then bStatus=OSD_SetOEMWallpaper()
Job_End(bStatus)
'End main

Scripting Guidelines