Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to create a .dll for VB
Message
 
À
30/08/2000 13:57:52
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00410896
Message ID:
00410913
Vues:
11
>>Ok, I was asked to build a dll that can
>>be accessed from a VB program. I built
>>a custom class that has the required code.
>>I marked it as olepublic. I put the class
>>in a project and then built a dll (I chose
>>single threaded). It built a dll file. I
>>wanted to test it from VFP so I ran a
>>program that does a set library to that dll,
>>additive and I get an 'Invalid dll' error.

What you're building isn't really one of the "API-style" libraries but rather a COM object. Register the DLL and use CreateObject("MyNewDll.WhateverClass"). If the code is in the Init you can pass parameters as well (for lost of reasons, I'd recommend against putting it in the Init, though - instead I would have a separate method).
The whole problem with the world is that fools and fanatics are always so certain of themselves, but wiser people so full of doubts. - Bertrand Russell
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform