Skip to main content

I am trying to create some custom screens using the Opportunity hook in the integrators toolkit for Maximizer Enterprise 7. When I run any ODBC code e.g. to insert an Opportunity, the command executes fine but when I close the form I get the error

"Data Manager returned an error code of 3006"
"The MicroKernel router detected an Invalid session."

This also happens when I am doing select queries as well.

Any ideas what is causing this??

Thanks

Alan
Original Post

Replies sorted oldest to newest

Hi, Alan.

Are you explicitly closing and releasing your connection objects after you are finished with them? Something like...
Dim objConn, objRS
Set objConn = CreateObject("ADODB.Connection")
objConn.Open "DSN=Maximizer Tutorial;User ID=MASTER;Password=control;"
Set objRS = CreateObject("ADODB.Recordset")
Set objRS.ActiveConnection = objConn
objRS.Open "SELECT * FROM Whatever"
objRS.Close
Set objRS = Nothing
objConn.Close
Set objConn = Nothing
Hi Gord,
I was closing the recordset and connection objects. I even copied your code just to ease the paranoia. I still get the same error. I can run Select or Insert commands but I still get the same error when control returns to Maximizer. Here is the code I am using

Dim con As ADODB.Connection
Dim rst As ADODB.Recordset
Dim sqlText As String

Set con = New Connection
Set rst = New Recordset
con.Open "DSN=Template;UserID=MASTER;Password=control;")
sqlText = "Select * from Opportunity"
rst.Open sqlText,con,adOpenKeyset,adLockOptimistic

MsgBox rst.Fields(4)
rst.Close
con.Close
Set rst = Nothing
Set con = Nothing

Thanks

Add Reply

Post
LEGAL INFO
CONTACT US
Copyright 2007-2018 Advoco Solutions Ltd. All Rights Reserved.
×
×
×
×
Link copied to your clipboard.
×