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

Merge.Merge method (Mergemod.h)

· 52CE 我爱测

The Merge method of the Merge object executes a merge of the current database and current module.

The Merge method of the Merge object executes a merge of the current database and current module. The merge attaches the components in the module to the feature identified by Feature. The root of the module's directory tree is redirected to the location given by RedirectDir.

The Merge method can only be called once to merge a particular combination of .msi and .msm files.

Syntax

Merge.Merge(
  Feature,
  RedirectDir
)

Parameters

Feature

The name of a feature in the database.

RedirectDir

The key of an entry in the Directory table of the database. This parameter may be null or an empty string.

Return value

This method does not return a value.

Remarks

Once the merge is complete, components in the module are attached to the feature identified by Feature. This feature is not created and must be an existing feature. Note that the Merge method gets all the feature references in the module and substitutes the feature reference for all occurrences of the null GUID in the module database. For more information, see Referencing Features in Merge Modules.

The module may be attached to additional features using the Connect method. Note that calling the Connect method only creates feature-component associations. It does not modify the rows that have already been merged in to the database.

Changes made to the database are saved if and only if the CloseDatabase method is called with bCommit set to TRUE.

If any merge conflicts occur, including exclusions, they are placed in the error enumerator for later retrieval, but does not cause the merge to fail. Errors may be retrieved through the Errors property. Errors and informational messages are posted to the current log file.

C++

See Merge function.

Requirements

Requirement Value
Version Mergemod.dll 1.0 or later
Header Mergemod.h
DLL Mergemod.dll

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)

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

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