Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VS2012 Publish Web Site dlls instead of cs-files

I have a simple ASP.NET project that I want to publish. I right-click on the project and press "Publish Web Site", however this generates all my .cs files to the selected folder, previously I've been getting dll files in my bin folder instead of the .cs files.

What am I doing wrong?

like image 320
Lord Vermillion Avatar asked Feb 12 '14 09:02

Lord Vermillion


People also ask

How do I publish my website in Visual Studio?

In Solution Explorer, right-click your project and choose Publish. If you're publishing this web app for the first time, next you see the Publish wizard. Visual Studio filters the list of destinations depending on the type of web app.

How do I run a DLL in Visual Studio?

You can easily open a DLL file in Visual Studio the same way you would any other file. To do so, click File in the menu bar at the top, followed by Open. Then click File and select the DLL file you want to open and click Open. This will open the DLL file in a new Resource Editor window.


2 Answers

The problem will be probably in the Publish setting. Please check if the option Precompile during publishing is selected. You can find the option here - Right click on the Project - Publish Web Site - section Settings - subsection File Publish Options - option Precompile during publishing.

like image 89
Pavel Cermak Avatar answered Oct 14 '22 15:10

Pavel Cermak


To publish your website in one DLL:

  1. In Visual Studio, open a web application project.
  2. Right click the project name in Solution Explorer, and then choose Publish.
  3. Select the Settings tab.
  4. Expand File Publish Options, and then select Precompile during publishing. Click Configure.

enter image description here

Refrence: https://msdn.microsoft.com/en-us/library/hh475319(v=vs.110).aspx

like image 2
M. Salah Avatar answered Oct 14 '22 17:10

M. Salah