To resolve this issue, update the VBScript code to use the new GPConnection object, and then update the lines that set up the ADODB.Connection object. The RetrieveGlobals userinfo object is no longer used in Integration Manager 10.0.
Make sure that you do not change the rest of the code. You have to change only the lines of code that create and set up the ADODB.Connection object. The following code is the updated code. You can paste this code into the Inventory Item sample integration After Document script event.
'Integration Manager 10.0 VBScript code
'A similiar version can also be found in the Integration Manager Script Library
Dim cn, cmd, rst, userinfo, Item, uom
Item = SourceFields("Inventory Item Main.ItemNumber")
uom = SourceFields("Item Pricing Specific.UofM")
'Old Integration Manager 9.0 code
'Create the retrieveglobals object
'Set userinfo = CreateObject("RetrieveGlobals9.retrieveuserinfo")
'Create the ADO connection object using RetrieveGlobals
'Set cn = userinfo.Connection
'cn.DefaultDatabase = userinfo.intercompany_id
'New Integration Manager 10.0 code
Set cn = CreateObject("ADODB.Connection")
cn.ConnectionString = "database=" & GPConnection.GPConnInterCompanyID
GPConnection.Open(cn)
'Create the ADO command object
Set cmd = CreateObject("ADODB.Command")
cmd.ActiveConnection = cn
cmd.CommandText = "Update IV00101 Set PRCHSUOM = '" & uom & "' where (ITEMNMBR='" & Item & "')"
Set rst = cmd.Execute
'release objects
Set rst = Nothing
Set cmd = Nothing
Set cn = Nothing
'Set userinfo = Nothing