• Introducing Dark Mode! Switch by clicking on the lightbulb icon next to Search or by clicking on Default style at the bottom left of the page!

COM-error after CreateBusinessObject

wherdes

Active Member
Hi List,

I'm trying to make a visual basic program (Visual Basic 6.0 SP 5) connecting to OneWorld via Com. Because my program did create an error after I log in into OneWorld I tried the famous addressbook example. This created the same error.
Steps I made: on a seperate development machine I compiled the application and created a setup-package. On another machine (fat-client with a standard OneWorld-installation) I installed and run the application. I installed the application on another site too (a different OneWorld-installation, server, etc.).

After this line:
Set OW = conn.CreateBusinessObject("OneWorld.FunctionHelper.1", l)
I get the error: "Type Mismatch"

What can be the problem??


Please help,
Walter Herdes

XE VB6 WIN2000/Win98


B7332 / XE / NT4 / SQL 7 / VisualStudio 6 SP5
 
Walter,

Did you include the COM objects you created with GenCOM in your
installation package? Also, did you declare OW as an object or as a
JDECOMCONNECTOR2Lib.OneWorldInterface?

Mark Collins

B7331/XE/NT/W2K/Oracle 8/VS6 SP5
 

wherdes

Active Member
Re: RE: COM-error after CreateBusinessObject

Hi Mark,

I did put the DLL created with gencom in the package.
I have a reference in my project to JDEComnonnect2.exe and the declaration/code of OW is:

Dim WithEvents OW As OneWorldInterface
Dim l As Long
...
l = conn.Login(frmLogin.txtUserName, frmLogin.txtPassword, frmLogin.txtEnv)
Set OW = conn.CreateBusinessObject("OneWorld.FunctionHelper.1", l)

and then I get the error.

Walter.



B7332 / XE / NT4 / SQL 7 / VisualStudio 6 SP5
 
RE: RE: COM-error after CreateBusinessObject

Walter,

I had a similar problem, and it turned out that the server name in the
jdeinterop.ini file was too long. It can only be twelve characters. If
this is the case, you can replace the server name with the server IP
address.

Good luck!

Mark
 
Top