Find out why Visual Studio’s publish fails

Have you ever had Visual Studio tell you your web application publish failed, but never gives you a reason why?  You’re not alone.  I’ve been putting off looking into this issue on a project and just found a way to get my answer right away.

Visual Studio 2008's Publish Failed message

Visual Studio 2008's Publish Failed message

Here’s what you should do inside of Visual Studio to find out why your publish failed.

  1. Click the Tools menu > then Options to bring up the Options dialog.
  2. Expand ‘Projects and Solutions’ on the left and click General
  3. On General, click ‘Show Output window when build starts’
  4. Now click on ‘Build and Run’ in the left tree
  5. Next select a value from the ‘MSBuild project build output verbosity’ drop down menu
  6. OK your way back to the main Visual Studio window
  7. The next time you Build or Publish your project, you should see the Output panel pop up.  If your publish is still failing, the answer will live inside the Output panel

Here’s a visual walkthrough of these instructions.

Tools > Options > Projects and Solutions > General

Tools > Options > Projects and Solutions > General

Tools > Options > Projects and Solutions > Build and Run

Tools > Options > Projects and Solutions > Build and Run

Visual Studio's Output Panel

Visual Studio's Output Panel

About Eric Fickes

Independent Internet Consultant by day. Skateboarder, Bass player, Husband and Father by night. You can hire me to build internet powered solutions
This entry was posted in .net, C#, development, microsoft, tips and tricks, Visual Studio and tagged , , , , , , , , , . Bookmark the permalink.

23 Responses to Find out why Visual Studio’s publish fails

  1. pouya says:

    hi,
    tnx a lot !

  2. rleven says:

    Thanks, you are a life saver!

  3. Eric Fickes says:

    Glad this helped out guys

  4. Mike says:

    brilliant!

  5. Tnert says:

    Thanks for clearing up this annoyance!

  6. Giova says:

    Thank you, this was really bugging me!

  7. Darwin says:

    Gracias amigo, me estaba volviendo loco con este error…gracias nuevamente…

  8. Avinash says:

    Thanks Eric ……….
    It solved my problem

    Avinash

  9. Yuri says:

    Thank you very much for detailed solution – it helped!

    Yuri

  10. jojo says:

    oops,it seems not working for me.there's no message that can help me to solve whatever bugs from the Output window.

    any ideas?

    • Eric Fickes says:

      jojo, Unsure why this wouldn't work for you unless your panels aren't visible for some reason. If your project is giving you trouble after building it, be sure to check the Error List ( View > Error List ).

      • jojo says:

        hi,eric.Thanks for your reply.I managed to build the project successfully,but somehow when it comes to publishing the bin folder,it fails.There’s no error in the error list.I even tried to restart my IIS,but it won’t work.

      • jojo says:

        sorry..it’s actually my mistake.I deleted a file from the physical folder,but I didn’t remove it from the solution file. :p

        anyway,thanks eric.great post anyway! :)

  11. Hi Man, Thx a Lot, Helped me and saved me time!

  12. David Croft says:

    quality – cheers mate

  13. Neo says:

    Excellent

  14. Marseld says:

    Very helpful post. Thank you.

  15. Raju Helge says:

    Nice Work Done.

  16. Masum says:

    It's Grate

  17. Carlos says:

    I found out the problem due to your post. thanks!

  18. oscar g says:

    Thaks a lot, this tip help me resolved my issue.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>