473,652 Members | 3,039 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Managed C++ Dll - Where's my output?

Hi,

I have created a very small test wrapper class in Managed C++ which
wraps up some very simple native code. I am using C# 2 + Visual Studio
2005 Beta 2.

I have the back end C++ library without CLR which is to be wrapped that
outputs fine to a static .lib as expected.

Then I import the .lib into a Managed C++ DLL (/CLR) and wrap it up in
a class. Everything compiles fine with no errors or warnings however my
DLL is not outputted into the debug folder.

It creates the .obj file and a manaifest file -
(myprogram.dll. intermediate.ma nifest) but there's no library (dll)
outputted.

I have checked all the settings and I am completely out of ideas. Why
isn't the DLL being outputted? Do I need to somehow declare what is
outputted and what isn't? I do recall dllimport and dllexport from back
in the day although it's a vague memory :)

I take it this obviously doesn't work like a normal .net assembly?
Please point me in the right direction. Thanks in advance.

Kind Regards,
Mark

Nov 17 '05 #1
4 1448
Hi quortex!
I have created a very small test wrapper class in Managed C++ which
wraps up some very simple native code. I am using C# 2 + Visual Studio
2005 Beta 2.


What project-type have you created?

For a C++/CLI assembly project you should take a "C++|CLR|Cl ass Library"
project (File|New|Proje ct...)

In the project properties under the "general" entry the should be the
following:
- Configuration Typ: Dynamic Library (DLL)
- Common language runtime support: Common Language Runtime Support (/clr)

And in the "Linker|General " there should be the pathe/filename of the
generated DLL.

--
Greetings
Jochen

My blog about Win32 and .NET
http://blog.kalmbachnet.de/
Nov 17 '05 #2
Hi,

Thanks for the reply. I just checked my project just incase but as I
thought yes I have a managed c++ project. It has /clr switch and is set
to be a DLL with linker output of $(OutDir)\$(Pro jectName).dll.

It is outputting the .manifest file so I guess that's another sign it's
setup correctly. Perhaps I have missed something with the internal
structure of my library it just contains two classes and their
corresponding header files. Everything is very simple very clean with
no warnings or errors.

This is really holding me up and driving me mad to be honest. Any
ideas?

Kind Regards,
Mark

Nov 17 '05 #3
Hi quortex!
it just contains two classes and their
corresponding header files. Everything is very simple very clean with
no warnings or errors.


What classes? Managed or Unmanaged?
You need to have at least a managed class!
Can you post a small code-snipped?
--
Greetings
Jochen

My blog about Win32 and .NET
http://blog.kalmbachnet.de/
Nov 17 '05 #4
Jochen,

DOH!

My apologies I can't believe it the dll was being outputted but it was
being outputted to a debug folder of the solution root rather than the
project root.

I did a search for the dll and found it :( Tragic tragic it was working
all along.

Thanks for your help.

Mark

Nov 17 '05 #5

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

Similar topics

1
2764
by: Yoni Rabinovitch | last post by:
Hi, We have a large code base of "regular" C++ code (not MFC, COM or ATL). With VC6.0, we used to compile the "regular" C++ code as static libraries (.lib files), and then we would link the .lib files with an MFC GUI "front end". The "regular" C++ can also run as a standalone .EXE (with no GUI).
0
925
by: quortex | last post by:
Hi, I have created a very small test wrapper class in Managed C++ which wraps up some very simple native code. I am using C# 2 + Visual Studio 2005 Beta 2. I have the back end C++ library without CLR which is to be wrapped that outputs fine to a static .lib as expected. Then I import the .lib into a Managed C++ DLL (/CLR) and wrap it up in
4
1455
by: Dan Diephouse | last post by:
I am attempting to write a DLL which wraps C# code. The issue at hand is a print driver allows you to extend it by writing a DLL. Seeing that VC++ seems to be hopelessly out of my mental reach, I thought I'd write the DLL in C#. Of course, it turns out I can't solely write the DLL in C# managed code. I have to create an unmanaged wrapper. So I have the following stub below which I need to fill in. I've gotten to the point where it...
87
5109
by: Robert Seacord | last post by:
The SEI has published CMU/SEI-2006-TR-006 "Specifications for Managed Strings" and released a "proof-of-concept" implementation of the managed string library. The specification, source code for the library, and other resources related to managed strings are available for download from the CERT web site at: http://www.cert.org/secure-coding/managedstring.html
1
2715
by: Stephen Walch | last post by:
I have a managed C++ assembly that wraps several unmanaged libraries. I excercise this assembly by calling it from a C# WinForms app running in the Visual Studio.NET 2003 dubugger. At a certain point in processing call _CrtDumpMemoryLeaks() to look for possible memory leaks in the unmanaged code. The function appears to execute, but I do not see the usual memory disgnostic information in the VS2003 output window. What is going on here?...
5
2290
by: raylopez99 | last post by:
I need an example of a managed overloaded assignment operator for a reference class, so I can equate two classes A1 and A2, say called ARefClass, in this manner: A1=A2;. For some strange reason my C++.NET 2.0 textbook does not have one. I tried to build one using the format as taught in my regular C++ book, but I keep getting compiler errors. Some errors claim (contrary to my book) that you cannot use a static function, that you must...
11
2339
by: =?Utf-8?B?aWduaGVucnk=?= | last post by:
I have a managed C++ project and two C# projects. All are class library projects. The C++ project links with native C++ static libraries and references to one C# project. The projects structure goes something like this. Proj2_MCPP --(references)--Proj1_CSharp Proj3_CSharp --(references)--Proj2_MCPP and Proj1_CSharp My objective is to link the DLLs produced by the 3 projects into a single DLL. I tried the following scenario.
4
2222
by: =?Utf-8?B?dmlwZXJ4MTk2Nw==?= | last post by:
We are having an issue with an application we are developing. We have a Legacy COM DLL in C++ that we have converted to Visual Studio 2008. This COM DLL has methods that are calling Managed C# assemblies as pass thru to support legacy applications in an effort to move our code to the new Code base. Our COM Object can be instantiated on Windows XP in any COM supported environment using Visual C++, Visual Basic, ASP.NET or ASP and works...
2
3194
by: chandramohanp | last post by:
I am having problem to delete a Managed C++ DLL that was used in a pure C# DLL even in the following scenario. 1. Launch the application. This applicatio has its own default applicaiton domain. 2. Create a new Application Domain. 3. Load the Pure C# DLL in the new applicaiton domain. This C# DLL uses managed C++ DLL. 4. Create a Proxy object using CreateInstanceAndUnwrap for the wrapper
0
8367
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8279
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8811
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8589
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7302
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6160
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5619
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
2703
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1591
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.