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

Dialog Box Overview

· 52CE 我爱测

The process of creating a dialog box in Windows Installer is similar to the process of creating a dialog box programmatically using a Microsoft Windows API dialog box template.

The process of creating a dialog box in Windows Installer is similar to the process of creating a dialog box programmatically using a Microsoft Windows API dialog box template. While a Windows dialog box template is stored in a null terminated–character string, Windows Installer stores the dialog box parameters in the Dialog table. The Dialog table contains an attributes column that is analogous to Window styles in the Microsoft Windows user interface API. However, the number of dialog style bits in Windows Installer is a reduced and specialized set.

To physically create the dialog box using the Windows user interface API, DialogBox is called and passes a pointer to the template. In Windows Installer, the dialog box is created during execution of one of the three UI sequence tables.

Windows Installer does not contain a default UI that package authors can utilize for their packages. It does contain a limited set of default dialog boxes that display error and information messages, but these are displayed only if Windows Installer queries the Dialog and UI Sequence tables and finds there are no custom dialog boxes available.

The installer SDK includes a minimal database named Uisample.msi that contains populated UI and execution sequence tables and a complete UI. This database is easily customized and merged on to any package.

Some standard actions and internal Windows Installer error conditions return a specific set of UI data and therefore require a dialog box with a specific set of controls to accommodate that data. Windows Installer checks two separate locations for the identifiers for these dialog boxes.

  • Windows Installer contains a set of embedded dialog box names. The custom action queries the Dialog table for these reserved names.
  • In each of the three UI sequence tables, dialog names with a sequence number of -1,-2, or -3 are displayed in response to exit, user requested exit, and fatal error messages from Windows Installer.

A complete list of reserved primary key dialog box names is available in dialog boxes. Note that the primary key dialog box name is only reserved by the installer and there is no specific implementation of the dialog box within Windows Installer. Package authors must still populate all the fields in the database that specify the attributes and controls of these reserved dialog boxes.

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)

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

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