?
Solved

VC++ Win32 project in .NET solution compiles as an .EXE file rather than .DLL

Posted on 2006-06-17
2
Medium Priority
?
552 Views
Last Modified: 2008-01-09
Hi,

I have a .NET solution consisting of a VB.NET Add-In project, a VC++.NET Win32 project which I'm using to store an image for my Add-In in a resource file and the Setup project for this solution.

I opened the VC++.NET's project properties window and changed its "Configuration Type" from "Application (exe)" (which was the default value when I added this projecvt to my solution) to "Dynamic Library (dll)" which is the format I need for my Add-In.

However, to my surprise, every time I compile this project I get an .EXE file instead of a .DLL file!!! I've changed the above property to a lot of different options out of curiosity and it always created the expected output format except for... DLL!!!

I tried to test this behaviour in a few test projects, and it looked like I was playing the lottery... One tested project worked and the output was DLL while a few others stuck with .EXE even if the selected "Configuration Type" was "Dynamic Library (dll)"  rather than "Application (exe)"!!!

Then, when I compile my solution (the add-in, resource file project and the setup project) at a certain point I'm getting the error message "Microsoft (R) Visual Studio registry capture utility has encountered a problem and needs to close".
If I close this message box by pressing its OK button, the setup carries on as nothing happened and compiles all three projects successfully!!!

Could anyone help?

Thanks!!!
0
Comment
Question by:sterlingdev
[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 Comments
 
LVL 48

Accepted Solution

by:
AlexFM earned 2000 total points
ID: 16925962
Maybe it is more simple to create new Win32 Dll project than to convert existing exe project?
Generally, such conversion is possible. It is necessary to compare all linker and compler options in Dll and exe projects, and make required changes. But I beleive that creating new Dll us mich better.
0
 

Author Comment

by:sterlingdev
ID: 16943397
I've recreated the VC++ project directly as a DLL and it worked!
Thanks!
0

Featured Post

NFR key for Veeam Agent for Linux

Veeam is happy to provide a free NFR license for one year.  It allows for the non‑production use and valid for five workstations and two servers. Veeam Agent for Linux is a simple backup tool for your Linux installations, both on‑premises and in the public cloud.

Question has a verified solution.

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

A basic question.. “What is the Garbage Collector?” The usual answer given back: “Garbage collector is a background thread run by the CLR for freeing up the memory space used by the objects which are no longer used by the program.” I wondered …
Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Suggested Courses

771 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