_XDocument2.DataAdapters Property

Gets a reference to the DataAdaptersCollection collection that is associated with a form.

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

Syntax

'Declaration
ReadOnly Property DataAdapters As DataAdaptersCollection
    Get
'Usage
Dim instance As _XDocument2
Dim value As DataAdaptersCollection

value = instance.DataAdapters
DataAdaptersCollection DataAdapters { get; }

Property Value

Type: Microsoft.Office.Interop.InfoPath.SemiTrust.DataAdaptersCollection

Remarks

Important

This member can be accessed only by forms running in the same domain as the currently open form, or by forms that have been granted cross-domain permissions.

Examples

In the following example, the DataAdapters property of the XDocument object is used to set a reference to a data adapter called "Main query":

object objDataAdapter;
objDataAdapter = thisXDocument.DataAdapters["Main query"];

See Also

Reference

_XDocument2 Interface

_XDocument2 Members

Microsoft.Office.Interop.InfoPath.SemiTrust Namespace