VC 2005 does not copy files when publishing a web site

I have recently converted a .net 1.1 web application to .net 2.0. The conversion went very well. I was very pleased with the wizard. The application runs well from inside the development environment. Problem is when I try and publish the web site... no files ever get copied to the output directory.

Any ideas would be appreciated

Bill

[361 byte] By [wjlong6] at [2007-12-30]
# 1

I'm assuming you are using "Publish Web" to publish a web site. This will pre-compile and publish your web site to a server. You have a few options you can use, such as setting whether your aspx and ascx pages are editable or whether to use fixed naming or not.

When you say "no files ever get copied", does this mean your destination is totally empty or you just don't see the files you expect?

-Mike-

MBund at 2007-9-5 > top of Msdn Tech,Visual Studio,Visual Studio MSBuild...
# 2

I had the same problem when I converted my VB.NET 2003 website to VS2005. It turned out that I had a missing end form tag(</form> ) in one of my aspx pages. Once I added the ending form tag It published fine. I was even able to reproduce this behavior by creating a new aspx page and deleting the ending form tag(</form>) and saving the file and publishing again. If you watch the output when publishing, the folder that it is building when it stops may be the culprit. That was the case on my conversion.

Hope this helps.

bsmith at 2007-9-5 > top of Msdn Tech,Visual Studio,Visual Studio MSBuild...
# 3

Thanks for the repro. I'll open a bug and we'll look into it!

-Mike-

MBund at 2007-9-5 > top of Msdn Tech,Visual Studio,Visual Studio MSBuild...
# 4

Problem is solved..

Turned out to be a similar problem. My web site uses multiple web.config files (one in the root and a few other is sub directories to control behaviour in those directories). The problem was an error in one of my web.config files (files first line was "<?xml version="1.0" encoding="utf-8" ?>" This is valid in .NET 1.1 I guess but not in .NET 2.0. The upgrade wizard changed it in the web.config file located in the root but not in the others... This is a problem with the wizard? The other thiing that seems to be a bug is the when I tried to publish with the web.config errors... It told me everything (complie and publish) was successful... It just did not complie anything or put anything in the output directory... It was completely empty... Perhaps Microsoft could fix this so that at least it gives an error mesage when an error happens.

The other wierd thing is that the application also ran without any problem (with the web.config errors) from within Visual Studio... It just would not publish.

Bill

wjlong6 at 2007-9-5 > top of Msdn Tech,Visual Studio,Visual Studio MSBuild...
# 5

I've gone ahead and opened a bug to look into the migration issue. Thanks for the repro and additional info!

MBund at 2007-9-5 > top of Msdn Tech,Visual Studio,Visual Studio MSBuild...
# 6

One additional thing. There is a bug in the way the runtime is calling visual studio -- which leads to VS to doing the right thing. We have identified the problem and will try to fix in the next release. Thanks again for the info.

MBund at 2007-9-5 > top of Msdn Tech,Visual Studio,Visual Studio MSBuild...
# 7
One last thing. Could you post or send me a copy of your web.config that caused the error, along with the folder location in your web folder? Thanks!
MBund at 2007-9-5 > top of Msdn Tech,Visual Studio,Visual Studio MSBuild...
# 8

I had the same problem and in my case the folder I was trying to write to did not have the correct permissions. Studio did not complaint or warn in any way. It simply stated the operation was successful although no files whatsoever were created in the target destination. I was deploying to an FTP site.

I granted write permissions to my account and everything went as planned.

madestro at 2007-9-5 > top of Msdn Tech,Visual Studio,Visual Studio MSBuild...
# 9
I am experiencing this same problem. I have two projects in this solution one will publish to the server through a mapped drive and the second indicates it has published with no files being copied.

There is only one web.config file. In the site.
There are no errors/warnings/messages on the Error list.

I checked all the forms have ending tags. Any other ideas on what could be blocking the publish process or what to check to reveal what might be the problem?

The build reports this:
********************************

Build started: Project: Settings, Configuration: Debug Any CPU
Settings -> E:\Projects\website\Settings\bin\Debug\Settings.dll
Build started: Project: Data, Configuration: Debug Any CPU
Data -> E:\Projects\website\Data\bin\Debug\Data.dll
Build started: Project: BISC.UI.WebControls, Configuration: Debug Any CPU
BISC.UI.WebControls -> E:\Projects\website\BISC.UI.WebControls\bin\Debug\BISC.UI.WebControls.dll
Build started: Project: Common, Configuration: Debug Any CPU
Common -> E:\Projects\website\Common\bin\Debug\Common.dll
Build started: Project: E:\...\website_site\, Configuration: Debug .NET
Validating Web Site
Building directory '/website_site/Controls/'.

Validation Complete
========== Build: 5 succeeded or up-to-date, 0 failed, 0 skipped ==========

**********************

The Publish Output is:

**********************
Settings -> E:\Projects\website\Settings\bin\Debug\Settings.dll
Build started: Project: Data, Configuration: Debug Any CPU
Data -> E:\Projects\website\Data\bin\Debug\Data.dll
Build started: Project: BISC.UI.WebControls, Configuration: Debug Any CPU
BISC.UI.WebControls -> E:\Projects\website\BISC.UI.WebControls\bin\Debug\BISC.UI.WebControls.dll
Build started: Project: Common, Configuration: Debug Any CPU
Common -> E:\Projects\website\Common\bin\Debug\Common.dll
Build started: Project: E:\...\website_site\, Configuration: Debug .NET
Pre-compiling Web Site

Building directory '/website_site/App_WebReferences/'.
Building directory '/website_site/App_Code/'.
Building directory '/website_site/Controls/'.
Pre-compilation Complete
Publish started: Project: E:\...\website_site\, Configuration: Debug .NET
========== Build: 5 succeeded or up-to-date, 0 failed, 0 skipped ==========
========== Publish: 1 succeeded, 0 failed, 0 skipped ==========

***********************

Gpat at 2007-9-5 > top of Msdn Tech,Visual Studio,Visual Studio MSBuild...

Visual Studio

Site Classified