Solved

DLLs

Posted on 1998-08-06
2
230 Views
Last Modified: 2010-04-02
How can we export an entire C++ class from a DLL. This can be done easily if we are using a a MFC dll but we do not want to extend an MFC dll. I suppose it can be done using
--declspec(dllexport) but then can this be used to export an entire class.
Please Help.
0
Comment
Question by:shayad
2 Comments
 
LVL 5

Accepted Solution

by:
tuvi earned 50 total points
ID: 1169579
#define DllExport    __declspec( dllexport )

class DllExport C
{
  // ... your class definition
};

Samething applies for import.
0
 

Author Comment

by:shayad
ID: 1169580
The example is a bit too short. It would have been great if the example was continued to incorporate 'import' too.
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Article by: SunnyDark
This article's goal is to present you with an easy to use XML wrapper for C++ and also present some interesting techniques that you might use with MS C++. The reason I built this class is to ease the pain of using XML files with C++, since there is…
Introduction This article is the first in a series of articles about the C/C++ Visual Studio Express debugger.  It provides a quick start guide in using the debugger. Part 2 focuses on additional topics in breakpoints.  Lastly, Part 3 focuses on th…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

758 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now