SetupSetPlatformPathOverride function

[This function is available for use in the operating systems indicated in the Requirements section. It may be altered or unavailable in subsequent versions. SetupAPI should no longer be used for installing applications. Instead, use the Windows Installer for developing application installers. SetupAPI continues to be used for installing device drivers.]

The SetupSetPlatformPathOverride function is used to set a platform path override for a target machine when working with INFs from a different machine. As such, it can refer to a different platform than it is currently running on. For dealing with media sources, it can refer to platforms that are no longer supported, such as Alpha, MIPS, and PPC. It removes the platform path override if none is specified.


BOOL SetupSetPlatformPathOverride(
  _In_ PCTSTR Override


Override [in]

Pointer to a null-terminated string that contains the replacement platform information. For example, "alpha" or "x86". This parameter may be NULL.

Return value

If the function succeeds, the return value is a nonzero value.

If the function fails, the return value is zero. To get extended error information, call GetLastError.

If GetLastError returns ERROR_NOT_ENOUGH_MEMORY, SetupSetPlatformPathOverride was unable to store the Override string.


SetPlatformPathOverride is used to change the source path when queuing files. If a platform path override has been set by a call to SetPlatformPathOverride, any setup function that queues file copy operations will examine the final component of the source path and if the final component matches the name of the user's platform, replace it with the override string set by SetPlatformPathOverride.

For example, consider a MIPS-platform machine where the platform has been set to Alpha by a call to SetPlatformPathOverride. After the platform path override has been set, a file copy operation is queued with a source path of \\pop\top\baz\mips\x.exe, the path will be changed to \\pop\top\baz\alpha\x.exe.

The paths of file copy operations queued before the path override is set are not changed.


Minimum supported client

Windows XP [desktop apps only]

Minimum supported server

Windows Server 2003 [desktop apps only]







Unicode and ANSI names

SetupSetPlatformPathOverrideW (Unicode) and SetupSetPlatformPathOverrideA (ANSI)

See also