DavidS
DavidS

Reputation: 259

Copy DLL From Assembly For Deployment

NET on my local machine I have a reference to a DLL on my local assembly folder. I was wondering how I can "package" this dll with the deployment of my website? When I deploy on the staging server it starts complaining that it does not have that dll. (It is not in the GAC of the staging server). Thank you.

Upvotes: 3

Views: 3123

Answers (3)

Ken Browning
Ken Browning

Reputation: 29101

If your referenced DLL will not be in the GAC of the targeted computer then you should place the DLL in your web site's \bin folder. For asp.net websites, referenced DLLs must exist in the GAC or in the \bin folder. Alternatively, you could install your DLL into the GAC of your target computer using something like a WebSetup project.

Upvotes: 2

Baget
Baget

Reputation: 3346

Visual Studio Save the Reference Location as relative paths so put in the a folder in your project and make sure the it proprieties "Copy Local" is true, it will make the VS to copy the file to the output directory.

Upvotes: 1

Judah Gabriel Himango
Judah Gabriel Himango

Reputation: 60041

Have you tried setting the DLL reference to CopyLocal = true?

Upvotes: 1

Related Questions