Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Creating DLL:s in VFP5?
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00089709
Message ID:
00089761
Views:
27
>Hi.
>
>I want to create a win32 DLL. I cannot use C or C++. Is there
>anothere way to create DLL:s. Can I use VFP5 or any other tool?
>
>/Magnus

You can create a DLL in VFP 5, but it's as an OLE server and accessed via the CREATEOBJECT() syntax.

With normal DLLs you would declare the function in the DLL and call it like any other function. For example, if you created a normal DLL in C++ with MyCalc as a function you might declare it and call it with:
DECLARE INTEGER MyCalc IN MyDLL;
  INTEGER int1, INTEGER int2
lnresult = MyCalc(5, 10)
However, if you built the same function as an OLE server DLL in VFP, you'd:
oMyObj = CREATEOBJECT('MyDLL.MyClass')
lnresult = oMyObj.MyCalc(5, 10)
hth,
George

Ubi caritas et amor, deus ibi est
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform