Solved

Borland C++ 5.02

Posted on 2000-03-29
4
1,421 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

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
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).

756 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