Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Passing Objects to ActiveX Server

Status
Not open for further replies.

Misled

Programmer
Sep 22, 1998
23
US
I have 3 projects: 1. The user interface. 2. The UI Business objects. 3. An ActiveX server.<br>
<br>
I want to pass an object from the UI Business objects to the server. This server will not be known at run time, so I have to create the server with CreateObject. The server does have a reference to the UI Business objects, so I can declare variables of the type I am trying to pass. However, when I try to pass the object to the server I get error 13, type unknown. What am I doing wrong? Is it not possible to pass objects to servers created with Createobject?<br>
<br>
The following is a code snippet from the UI Business object:<br>
<br>
dim oServer as object<br>
<br>
public sub Inialize(oObject as UIObject, sServerName as string)<br>
<br>
set oServer = CreateObject(&quot;sServerName&quot;)<br>
oServer.inialize oObject<br>
<br>
end sub<br>
<br>
The following is a code snippet from the server. Keep in mind the server has a reference to the UI Business Object project:<br>
<br>
dim svrUIObject as UIObject<br>
<br>
Public sub Inialize(oObject as UIObject)<br>
<br>
set svrUIObject = oObject<br>
<br>
end sub<br>

 
At which line of code are you getting this error?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top