Share via


_Application3.ActiveWindow Property

Gets a reference to a WindowObject object that represents the currently active window.

Namespace:  Microsoft.Office.Interop.InfoPath
Assembly:  Microsoft.Office.Interop.InfoPath (in Microsoft.Office.Interop.InfoPath.dll)

Syntax

'Declaration
ReadOnly Property ActiveWindow As WindowObject
    Get
'Usage
Dim instance As _Application3
Dim value As WindowObject

value = instance.ActiveWindow
WindowObject ActiveWindow { get; }

Property Value

Type: Microsoft.Office.Interop.InfoPath.WindowObject
A WindowObject object that represents the currently active window.

Implements

_Application2.ActiveWindow

Remarks

Using the ActiveWindow property, you can gain immediate access to the window that is currently being viewed by the user, and then use the properties and methods of the Window object that it returns.

Examples

In the following example, the ActiveWindow property is used to gain access to the MailEnvelope property of the WindowObject object that returns a MailEnvelopeObject object.

MailEnvelope email = thisApplication.ActiveWindow.MailEnvelope;
email.Subject = getNode(@"/mtg:meetingAgenda/mtg:subject").text;
email.To = aliases + "; ";
email.Visible = true;

See Also

Reference

_Application3 Interface

_Application3 Members

ActiveWindow Overload

Microsoft.Office.Interop.InfoPath Namespace