Solved

Borland C++ 5.02

Posted on 2000-03-29
4
1,434 Views
Last Modified: 2013-12-26
I need to implicitly link a dll with my exe in Borland C++ 5.02.

I have an example for Builder, and this does this(I beleave) with USELIB(..);
, however this is what I need, to do the same with BC++ 5.02 as USELIB does with Builder.

Error is caused by linker,
Unresolved External...    
0
Comment
Question by:ekinee
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 14

Accepted Solution

by:
AlexVirochovsky earned 50 total points
ID: 2669658
It is same mechainique, but little other.
1. Make lib file with help of impdef/
implib : if this Borland DLL,
use direct implib, if MS: make beforehand def file with impdef and after that implib.
2. Include you lib file in you project.
3. Make h file with prototypes of
  DLL function and add in you cpp file.
4. Simple use MyDllFunction(..)

I hope, it helps. Alex
 
0
 
LVL 3

Expert Comment

by:JPM
ID: 2669964
AND don't forget to put inside Headers some code like this one :

#if defined  (MAKEDLL)
     #define _APPLI  __export
#elif defined (USEDLL)
    #define _APPLI  __import
#else
    #define _APPLI
#endif

and in IDE :  Options/Compiler/Defines
put   MAKEDLL                  for  the DLL
put   USEDLL                     for the EXE

Jean-Paul
0
 
LVL 3

Expert Comment

by:JPM
ID: 2669970
sorry i forgot something :
define your classes as :

class _APPLI  myclass.....
0
 

Author Comment

by:ekinee
ID: 2675895
I'm thanking.
0

Featured Post

What Is Transaction Monitoring and who needs it?

Synthetic Transaction Monitoring that you need for the day to day, which ensures your business website keeps running optimally, and that there is no downtime to impact your customer experience.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

What is Node.js? Node.js is a server side scripting language much like PHP or ASP but is used to implement the complete package of HTTP webserver and application framework. The difference is that Node.js’s execution engine is asynchronous and event…
JavaScript has plenty of pieces of code people often just copy/paste from somewhere but never quite fully understand. Self-Executing functions are just one good example that I'll try to demystify here.
The viewer will learn how to dynamically set the form action using jQuery.
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

724 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question