Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Com object malfunctions
Message
From
17/05/2002 03:17:11
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Title:
Com object malfunctions
Miscellaneous
Thread ID:
00658023
Message ID:
00658023
Views:
43
Hi all,

In Visual FoxPro I built a COM object (a COM DLL) with a number of
procedures.
All classes in it were defined as "OLEPUBLIC"

When calling a procedure in the Com object (from a Delphi application) on
the same PC as where the object was made, no problem occurs.

In the VFP setup wizard in step 2, the VFP runtime and Com components (the
DLL itself) were checked to be included.

After installation on another computer and calling a procedure in the COM
object from Delphi a message appears saying: "Library not registered".
Inspection of the registry however learns that the object has been
registered.

The Delphi code looks as follows:

****************************************************************************
*
procedure TForm1.Button1Click(Sender: TObject);

var

oparam1 : olevariant;

begin

file://Creating instance of com object named : comdemo.Form1

oparam1 := createoleobject('pfcomobj.pfspecform');

oparam1.GetScreenByID(1);

end;

****************************************************************************
*


Creation of the object goes well, but the error message occurs when the
specified function (in the case 'GetScreenByID' is called.

Registering the DLL on the 'new' machine through regsvr32 makes no
difference.



What could be wrong? Which library is not registered?


TIA

Jan Lavrijsen
Next
Reply
Map
View

Click here to load this message in the networking platform