Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to impement an external DLL in VFP
Message
De
09/09/2015 11:41:26
 
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows 7
Network:
Windows 2003 Server
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01624395
Message ID:
01624398
Vues:
158
>Hi Gang!
>
>Hate to bother you today.
>
>We have been told to recode our EZSIGN application (written in VFP 9.0 SP1). We have to use the RBA_SDK dll's to implement it.
>
>So..... we have tried various things to open the DLL and use it... like
>
>lo = CREATEOBJECT('rba_sdk.rba_api") to no avail.
>
>We tried registering the DLL but it will not load.
>
>So I've included a screenshot of the DLL being referenced in Visual Studio.
>
>Can you give some direction for us to implement it in VFP ?
>
>Thanks!

Probably wouldn't help much, but I did run into situation where compiling a DLL wouldn't work in VFP -- resulted in either a complete hang of VFP environment (in the case of VFP6), or ending up with an invalid TLB (in VFP9 -- but after an extended pause). Apparently VFP is running afoul of Windows when it tries to automagically register the DLL, and apparently the TLB is being generated sometime afterwards -- so in the case in VFP6, cancelling the process means the DLL is neither registered nor is there a TLB created; in the case of VFP9 the DLL registration fails (the long delay) and due to error in registration, the TLB file generated contains invalid information -- so you're unable to try to manually register the DLL because the TLB is not valid (you get "type library invalid" error). The workaround is to launch VFP as administrator before compiling to DLL (i.e. right-click on icon, then select "run as administrator").
On a similar note, registration of DLL will fail if the proper runtime library files (as well as any other DLLs that the DLL is dependent upon) aren't registered in Windows.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform