Share via


_Application3.NewADODBRecordset method

Creates and gets a reference to an empty ActiveX Data Objects (ADO) Recordset object.

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

Syntax

'Declaration
Function NewADODBRecordset As Object
'Usage
Dim instance As _Application3
Dim returnValue As Object

returnValue = instance.NewADODBRecordset()
Object NewADODBRecordset()

Return value

Type: System.Object
A reference to an empty ActiveX Data Objects (ADO) Recordset object.

Implements

_Application2.NewADODBRecordset()

Remarks

If the form is not fully trusted, the NewADODBRecordset method will return a "permission denied" error.

Note

This method is not intended to be used in a managed-code form. To query a Microsoft SQL Server database, use the System.Data.SqlClient class and its associated members by adding a reference to System.Data component and a using clause to System.Data.SqlClient.

Examples

object adoRS = thisApplication.NewADODBRecordset();

See also

Reference

_Application3 interface

_Application3 members

NewADODBRecordset overload

Microsoft.Office.Interop.InfoPath namespace