大网数据广告活动
安装更新与部署

UiCreatePatchPackage (Patchwiz.dll)

· 52CE 我爱测

The UiCreatePatchPackage function takes a package creation file (.pcp file) and generates a Windows Installer patch package (.msp package).

The UiCreatePatchPackage function takes a package creation file (.pcp file) and generates a Windows Installer patch package (.msp package). Calling Msimsp.exe is the recommended method for using Patchwiz.dll. The UiCreatePatchPackageEx function is available in version 4.0 of Patchwiz.dll and extends the functionality of the UiCreatePatchPackage function.

UINT UiCreatePatchPackage(
  LPCTSTR szPcpPath,              
  LPCTSTR szPatchPath,            
  LPCTSTR szLogPath,             
  HWND hwndStatus,                
  LPCTSTR szTempFolder,           
  Bool fRemoveTempFolderContents  
);

Parameters

szPcpPath

Full path to the patch creation properties file (.pcp file) for this patch.

szPatchPath

Full path to the Windows Installer patch package (.msp file) that is to be created. This parameter may be NULL or an empty string but may not be omitted. If it is NULL or an empty string, the function uses the value of PatchOutputPath in the Properties Table (Patchwiz.dll).

szLogPath

Full path to a text log file that will be appended. This parameter may be NULL or an empty string but may not be omitted.

hwndStatus

Handle to a window that displays the status text. This parameter may be NULL or an empty string but may not be omitted.

szTempFolder

Location for temporary files. This parameter may be NULL or an empty string but may not be omitted. The default location is %TMP%\~pcw_tmp.tmp\.

fRemoveTempFolderContents

If TRUE, remove the temporary folder and all of its contents if present. If FALSE, and folder is present, the function fails.

Return Values

See the table in Return Values for UiCreatePatchPackage.

Remarks

For an example of authoring a .pcp file and using UiCreatePatchPackage to generate a Windows Installer patch package, see the section A Small Update Patching Example.

Creating a patch requires an uncompressed setup image, such as an administrative image or an uncompressed setup image from a CD-ROM. UiCreatePatchPackage does not generate binary patches for files in cabinets.

Source: Microsoft Learn / Windows Win32 documentation by Microsoft and contributors. Documentation licensed CC BY 4.0. Code samples are covered by the MIT License. Converted from Markdown, with links normalized and embedded media omitted.

资料来源与适用范围

资料来源
Microsoft Learn / Windows Win32 documentation
适用范围
Windows Win32 API · Source date 05/31/2018
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY 4.0 (documentation), MIT (code samples)

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。