Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Creating C/C++ Libraries...
Message
 
À
20/06/1997 12:45:12
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00037152
Message ID:
00037170
Vues:
32
> Can anyone answer a question I have about creating libraries in > C/C++? > > I am new to programming in Visual C++ and am trying to work through > learning how to create external libraries for VFP. I am using Borland > C++ 5.01 and am unable to link my libraries. Currently, I have been > trying to do a simple "Hello, World" function, following the > explanations in the Professional Features Guide. > > This is my code ; > > // include the library construction header file > #include > > void hello(ParamBlk *parm) // the function definition > { > _PutStr("\nHello, World!\n"); //print the message > }; > > // the FoxInfo structure registers the function > FoxInfo myFoxInfo[]={ > {"HELLO",(FPFI) hello, 0, ""}, > }; > > //the FoxTable structure > FoxTable _FoxTable={ > (FoxTable *) 0, sizeof(myFoxInfo)/sizeof(FoxInfo), myFoxInfo > }; > > The source compiles okay, but when I try to link the file, I get this > message... > > Error: Unresolved external '__PutStr' referenced from module > mhello.c Have you included winapims.lib in the link list? (I'm not sure if this is compatible with Borland or not). This is in the VFP\API directory. /Paul
Paul Russell
EMail: prussell@fox.nstn.ca
Phone: (902) 499-5043
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform