Share via


UI2.Confirm Method

Displays a message box with buttons for input from a user.

Namespace: Microsoft.Office.Interop.InfoPath
Assembly: Microsoft.Office.Interop.InfoPath (in microsoft.office.interop.infopath.dll)

Syntax

'Declaration
'Usage

Parameters

  • bstrPrompt
    The text message to be displayed.
  • lButtons
    Specifies the number and type of buttons to display. You may specify any of the values of the XdConfirmButtons enumeration.

Return Value

An XdConfirmChoice enumeration.

Example

In the following example, the Confirm method of the UIObject object is used to display a dialog box with Yes and No buttons:

thisXDocument.UI.Confirm("Do you wish to continue?", XdConfirmButtons.xdYesNo);

See Also

Reference

UI2 Interface
UI2 Members
Microsoft.Office.Interop.InfoPath Namespace