Share via


_XDocument4.HostName property

Gets the name of the application hosting InfoPath as a control.

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

Syntax

'Declaration
ReadOnly Property HostName As String
    Get
'Usage
Dim instance As _XDocument4
Dim value As String

value = instance.HostName
string HostName { get; }

Property value

Type: System.String
The name of the host application.

Implements

_XDocument3.HostName

Remarks

This property is intended for use in scenarios where InfoPath is hosted as a control in another application and code running in InfoPath needs to access the name of the host application. Typically the host application name returned will be used in the title bar text of dialog boxes instead of "Microsoft Office InfoPath".

For detailed information about hosting InfoPath as a control in another application, see the article titled "Hosting the InfoPath Form Editing Environment in a Custom Web Form" on the InfoPath Developer Portal on MSDN.

See also

Reference

_XDocument4 interface

_XDocument4 members

HostName overload

Microsoft.Office.Interop.InfoPath namespace