Create ASP.Net default website error

I am using VSTS 2008 and I am using Create New ASP.Net Website and using default / auto-generated files.

My questions:

  • How can I use a command line script (msbuild) to automatically build an ASP.Net website?
  • I want to create a website in a DLL that can be easily copied for a later IIS server.

Any examples or quick answer how to accomplish these tasks in msbuild?

EDIT1: There are no sln and csproj files in the website folder. Here's a link.

http://tinypic.com/view.php?pic=dra5jp&s=5

This is how I create in VSTS 2008.

http://i40.tinypic.com/208zfxv.jpg

0


source to share


2 answers


I am using VS.NET 2005 and use this command to build my asp.net web app in release mode:



cd "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\"
MSBuild "C:\Projects\MyProject.csproj" /t:Rebuild /p:Configuration=Release /verbosity:quiet /p:WarningLevel=0

      

+1


source


"Web Applications" have .csproj files, "Web Sites" do not. http://damieng.com/blog/2008/02/07/web-site-vs-web-application

You want to compile it using aspnet_compiler.exe in bin directory C: \ windows \ framework \ version

http://msdn.microsoft.com/en-us/library/ms178466.aspx



An easier way is to use the deployment projects or the Publish Web Site command in Visual Studio. (Right click on website)

http://weblogs.asp.net/scottgu/archive/2008/01/28/vs-2008-web-deployment-project-support-released.aspx

+1


source







All Articles