eConnect_Requester Method

Use the eConnect_Requester method to retrieve Microsoft Dynamics GP data in an eConnect document.

Warning: This method is obsolete and will be removed in a future version of eConnect.

Class

Microsoft.Dynamics.GP.eConnect.eConnectMethods

Syntax

public string eConnect_Requester(
    string connectionString,
    EnumTypes.ConnectionStringType connectionType,
    string sXML
)
Parameters

Name

Data type

Description

connectionString

string

Specifies your data server and database.

connectionType

Microsoft.Dynamics.GP.
eConnect.EnumTypes.
ConnectionStringType

Use the ConnectionStringType enumeration member that specifies the type of your data server. ConnectionStringType includes the following members:

SqlClient

OleDB

sXML

string

An eConnect XML document.

Return Value

Type: string

The string is an XML document that represents the requested data.

Remarks

This method is obsolete. Replace existing calls to the eConnect_Requester with the GetEntity method.

To use the eConnect_Requester method to retrieve a document, create an eConnect XML document that specifies the document to retrieve. The document must use the RQeConnectOutType schema and the eConnectOut node to identify the document.

If an error occurs, the method throws an eConnectException, application exception, or exception.

Examples

The following Visual Basic .NET example uses the eConnect_Requester method to retrieve and display an XML document:

Dim ConnectionString As String
Dim eConnectObject As New eConnectMethods
Dim xmlDoc As XmlDocument
'Set the connection string
'This connection string uses integrated security to connect to the
'TWO database on the local computer
ConnectionString = "Data Source=localhost; Integrated Security=SSPI;" _
    & "Persist Security Info=False; Initial Catalog=TWO;"
'Instantiate an eConnectMethods object
Dim eConnectObject As New eConnectMethods
'Display the XML document in a textbox
ReturnData_TextBox.Text=eConnectObject.eConnect_Requester(ConnectionString, _
    EnumTypes.ConnectionStringType.SqlClient, _
    xmlDoc.OuterXml)

See Also