473,414 Members | 2,030 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,414 software developers and data experts.

share object between DLLs

hello,

I'd like to know if it possible to share objects between several DLLs.
I read I had to use #pragma data_seg() but how to specify this "area"
to the others DLLs ? ( I put the #pragma in my header and added SECTION
..... in my .def)
If there is another (easier) way to do it, I'll be glad to hear it.

thanks in advance

yann

Aug 2 '05 #1
3 1646
cyan wrote:
hello,

I'd like to know if it possible to share objects between several DLLs.
I read I had to use #pragma data_seg() but how to specify this "area"
to the others DLLs ? ( I put the #pragma in my header and added SECTION
.... in my .def)
If there is another (easier) way to do it, I'll be glad to hear it.

As standard C++ knows not of `DLL's, please ask your question in a
newsgroup specific to your platform.

HTh,
--ag
--
Artie Gold -- Austin, Texas
http://it-matters.blogspot.com (new post 12/5)
http://www.cafepress.com/goldsays
"If you have nothing to hide, you're not trying!"
Aug 2 '05 #2

cyan wrote:
hello,

I'd like to know if it possible to share objects between several DLLs.
I read I had to use #pragma data_seg() but how to specify this "area"
to the others DLLs ? ( I put the #pragma in my header and added SECTION
.... in my .def)
If there is another (easier) way to do it, I'll be glad to hear it.

thanks in advance

yann

Why do not use classFactory paradigm ?

Dll 1
MyObject myObjl
MyObject * GetMyObject ()
{
return myObj;
}

Dll 2,3,4
LoadLibrary (Dll1);
GetProcAddres ("GetMyObject");

Aug 2 '05 #3
On 2 Aug 2005 08:23:03 -0700, "cyan" <ya***********@yahoo.fr> wrote:
hello,

I'd like to know if it possible to share objects between several DLLs.
I read I had to use #pragma data_seg() but how to specify this "area"
to the others DLLs ? ( I put the #pragma in my header and added SECTION
.... in my .def)


It's better to ask in comp.os.ms-windows.programmer.win32 or for whatever
OS you are trying to write for.

In any case, you should take a look at Interprocess Communication methods,
which is the most traditional way of doing stuff.

Aug 2 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

16
by: ad | last post by:
I have write a clss, say DM.cs, and I save it in a independent directory like c:\MyUtil I have a new project in c:\proj1. When I use VS to add the existed c:\MyUtil\DM.cs to the new project,...
7
by: isamusetu | last post by:
anybody knows how to share the dll between the process? I know there is a way to set the #pragma data_seg in the visual studio 6.0 C++, that can make the dll can be shared between the multiple...
5
by: Rich | last post by:
Hi there, For a quite big application, I need to get large amount of data within a static library (xxx.lib) and put them in a database (a class, say we call it CData), and then make it...
3
by: Adam | last post by:
We have a web site that uses .vb for the web pages and .cs for a class module. We are getting the error in .NET 2.0 and VS 2005 beta 2. It does work with .NET 1.1. When trying to access a page...
4
by: | last post by:
Hi, Im running IIS and all my data is stored on a network share e.g \\10.0.0.111\domain.com\main The problem i'm facing is that i dont know how to point my aspx.vb files to any dlls in the bin...
8
by: Oenone | last post by:
Is it possible to create an object which can have methods and properties, but which can also be treated as a string? I'm trying to create a wrapper around the IIS Request.Form object which...
4
by: moondaddy | last post by:
I have some pubic Enums I like to use throughout my application. Now I'm parsing the application out into smaller DLLs or projects. How an I share a common Enum across all the projects? ...
4
by: Jeremy S. | last post by:
We're in the process of writing a new Windows Forms app and the desktop support folks want for it to be run from a network share. I know it's possible (i.e., just have the framework on the clients...
9
by: axs221 | last post by:
I am trying to move some of our large VBA Access front-end file into ActiveX DLL files. I created two DLL files so far, one was a module that contains code to integrate into the QuickBooks...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.