Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to build a DLL?
Message
 
À
07/11/2000 17:06:10
Information générale
Forum:
Visual C++
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00439042
Message ID:
00440274
Vues:
15
This will start you off the right direction.
Make it simple to start so you can learn. Use the app wizard to generate a regular dll and watch what it does. Construct the dll app object.
Write your function in the generated dll code to look like this ( this is MFC code ):


// declare the dll function ret
extern "C" __declspec(dllexport) int ret(int i)
{
AFX_MANAGE_STATE(AfxGetStaticModuleState());
TRACE( "Entering Return value \n");
return i;

}



Link and compile with your calling program.

This will return whatever you send it from you calling program.

This is the code you add to the generated code along with the constructor code for the app class. You can get this to work and then build on it by adding a diaog box for input etc...
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform