Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can anybody help me creating a class
Message
From
11/08/1998 06:10:08
 
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00125162
Message ID:
00125507
Views:
11
>You aren't creating a callable DLL like a WinAPI DLL call. You've created an OLE server. I'm not a VB programmer, but your VB code should look more like:
>
>dimension oVFP as object
>oVFP = CreateObject( "classlibname.vfield" )
>oVFP.InsFld()
>
>I use .vcx files for my servers. I'm not sure what the first part of the server name should be. I'd try the base filename of the DLL file.
>
>I think I'd also code it just a little different so VFP knows it needs to include support for the ALTER TABLE command when it compiles:
>
>kpk = tabname + " ADD column " + ...
>alter table &kpk
>
>that is only macro expand the clauses of the command and not the whole command.
>
>>>You have to create a class and make it OLEPUBLIC to make it an OLE server. You create a public method that would do the ALTER TABLE command. Then you just call that method of the server.

With your suggestion , I created DLL. It is working but the only thing that we have to do is is copy the DLL and associated TLB (Type Library) to the client's machine and REGESTER THE DLLs. by issuing command,

REGSVR32 Dllfile

Note : TLB file is must. From VB, go to the project references, and add the reference.
To check whether the DLL is installed use CLASS BROWSER available in VFP .

The question is My client machine is calling above DLLs correctly, But I doubt that is because I installed OLE Automation server by making DLLs as distributed disks using setup. I checked the (Install OLE Automation Componenets). Now How to delete the OLE Automation server that I distributed.

Without OLE Automation server , Will those DLLs work ?

--satya
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform