Hi all,
We try to use ADODB with such
VB-code
-------------------------------------------------------------------
Public conn As New ADODB.Connection
Public online As EQL_Session
Public Proc As Variant
Public OL As New OnLn
Dim Term As New Terminal
Sub Connect()
Dim srv As New ADODB.Recordset
. . . . . . . . .
strCnn = "Provider=EQL OLE DB Provider;Data Source="
strCnn = strCnn + "'" + CStr(DS) + "'" + ";User Id=" +
CStr(UID) + ";Password=" + CStr(PSW) + "; "
conn.Open strCnn
Set online = srv.fields(0).value
Set
Proc = srv.fields(1).value
srv.Close
Set srv = Nothing
If conn.state = adStateOpen Then
MsgBox "Connection is created"
End If
end_connect:
End Sub
Sub Disconnect()
OL.done_online
Term.done_online
Set online = Nothing
Set Proc = Nothing
Set conn = Nothing
End Sub
Sub CashTone()
Proc.OutTone snd_len, snd_tone
End Sub
---------------------------------------------
But in our xBase++ code we can see var.proc as
AutomationObject but we don't have a
outtone method for it
LOCAL oConnection, srv, proc, strCnn, online
oConnection := CreateObject('ADODB.Connection')
srv := CreateObject('ADODB.Recordset')
oConnection:Provider:='EQL.EQL.1'
strCnn := "Provider=EQL OLE DB Provider;Data Source='1;0';"
strCnn += 'User Id=1;Password=0;Extended Properties =
"Protocol=L2Com.HcComSessionCreator"'
oConnection:Open(strCnn)
srv:callmethod('Open', "EQL_service", oConnection,,,512)
online := srv:fields(0):value
proc := srv:fields(1):value
srv:Close()
proc:calMethod('OutTone',10,10)
online:destroy()
proc:destroy()
oConnection:Close()
oConnection:Destroy()
srv:Destroy()
Any good idea?
Thanks