Solved

Visual stuido 2010 - How to include used references in a build

Posted on 2013-05-23
2
174 Views
Last Modified: 2014-02-25
Hi Experts

I have a Visual stuido project, when Building a release of the code I want the used references comipled into the Exe or have them located in the Exe path, is there an option for me to do this?
0
Comment
Question by:MrDavidThorn
2 Comments
 
LVL 15

Accepted Solution

by:
ChloesDad earned 250 total points
ID: 39192711
Assuming that you are using the full version of VS2010 and not the express version of VB, then you need to add a setup project and create a solution. This will then do almost all of the work for you.

Click File - Add - New Project

In the project types list open up "Other Project Types" then select setup & Deployment and chose Setup Project.

Once you have added the project then you add the exe and other files that you want to install on the target machine and can create the folder paths etc. It is very powerful in what it can do for you.
0
 
LVL 40

Assisted Solution

by:Jacques Bourgeois (James Burger)
Jacques Bourgeois (James Burger) earned 250 total points
ID: 39197867
First of all, you do not need to do that for references to the framework dll. Same as Windows is needed to run a Windows application, the framework is a prerequisite for any station that needs to run a .NET application. So these dlls must already be installed on the users stations.

Note also that you must inquire as to whether you have the right to distribute the dlls. This is different for each dll. For instance, you cannot distribute stuff from the Office installation, Office must be installed separately on the users computers if your application needs it.

For the other dlls, you have 2 options.

Click on the dll in the references and set Copy Local to True in the Properties window. This will copy the dll in the application directory when you compile it, and most installations scenarios will automatically include these dll for you. Note that Copy Local is disabled if the Embed Interop Types is set to True.

The second option is Embed Interop Types. If you set it to True, the parts of the dll that are needed by your application ends up compiled into the application itself. This does not work will all dlls however, mostly with COM dlls.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

For a while now I'v been searching for a circular progress control, much like the one you get when first starting your Silverlight application. I found a couple that were written in WPF and there were a few written in Silverlight, but all appeared o…
Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …

895 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

11 Experts available now in Live!

Get 1:1 Help Now