473,385 Members | 2,013 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,385 software developers and data experts.

Best way to use unmanaged C++ from C#

I'm currently building a gui in C# in which i'd like to use my
extensive library of C++ classes. Ideally keeping the inheritence tree
intact. Right now I'm wrapping each unmanaged C++ class with a managed
C++ class. Is this the best way to go about things? Or can I use IJW
somehow? Or something different entirely?

Thanks in Advance,
Robert Conde
Jul 21 '05 #1
1 1406
I've had a similar problem. I can see two solutions:

1. You convert your library to managed c++. Might be a lot of work if we're
talking 100+ classes.

2. What I did was find the entry points into the unmanaged code library and
created wrappers that just wrapped those few classes.

Disclaimer: I am by no means an expert. :-)

I've done both, altho I did 1. the hard way with a very small set of classes
just as a test.

--Ola

<jaha@[REMOVE]jahamusic.com> wrote in message
news:nb********************************@4ax.com...
I'm currently building a gui in C# in which i'd like to use my
extensive library of C++ classes. Ideally keeping the inheritence tree
intact. Right now I'm wrapping each unmanaged C++ class with a managed
C++ class. Is this the best way to go about things? Or can I use IJW
somehow? Or something different entirely?

Thanks in Advance,
Robert Conde

Jul 21 '05 #2

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

Similar topics

4
by: tixydigit | last post by:
Hi everyone! I'm a newbee coding C++ but I've coded in other (simpler) languages for some 10 years now. I'm looking for a good developing tool for my PC but I have no clue wich one's the best....
5
by: Philippe Bertrand | last post by:
Using C#, I want to send a byte array to an unmanaged function with the minimum amount of copies. The array is input only and won't be modified (its copied on the unmanaged side). I'm currently...
4
by: 0to60 | last post by:
I'm trying to create a .dll with VS.NET 2003 Architect that contains a math computational component. I need the guts of the thing to be in native code, as performance is key for that part. But, I...
0
by: Johannes Unfried | last post by:
Problem Best practice needed to marshal STL data from managed code to unmanaged code & vice vers Details managed code is written in managed C++ & accesses the unmanaged code (i.e. lives in a...
4
by: Bae,Hyun-jik | last post by:
Hi, What is the best case for accessing managed code from unmanaged C++ code, considering that the unmanaged code doesn't have managed extension? Please reply. Thanks in advance. Regards,...
1
by: jaha | last post by:
I'm currently building a gui in C# in which i'd like to use my extensive library of C++ classes. Ideally keeping the inheritence tree intact. Right now I'm wrapping each unmanaged C++ class with a...
5
by: | last post by:
Hi, In our system we get image buffers through a native dll as void*. We want to manage several of this blocks by C# objects an pass them wen needed to a native image processing library. What...
20
by: Joe | last post by:
Is any one charting packing considered to be the "best"? We've used ChartFX but wasn't too happy about the way data had to be populated along with some other issues which slip my mind right now and...
2
by: dan | last post by:
Our company has a large legacy application that we would like to convert to run under the CLR. The application consists of a large collection of Dlls that have been written in C++ and MFC over...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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,...

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.