Thursday, May 2, 2013

How to Publish Website in Visual Studio 2012

4 comments
This article is about publishing the website in visual studio 2012. To publish website in asp.net 4.5 framework follow the given steps:

If you want to publish web application in Visual studio 2012 then follow this article:
Publish Web Project(Application in Visual Studio 2012.

 To publish website in asp.net 4.0 see this article Publish website in Visual studio 2010.

I have taken an example which show with diagram the whole process of publishing website.

Step 1:  Click on Build Menu in VS 2012 and then click on Publish Web Site as shown in the picture below:

Publish website in visual studio 2012

Step 2:       Select the Target Location where you want to save the published website and then click on Ok button as shown in picture below:

website publish in vs 2012

Step 3:     Site would be published to the folder specified in step 2 above.

4 comments:

  1. Thank you for the instruction, but if I have an sql database in the folder app_data, do I need to use Microsoft Sql Managment Studio, if i want to host my website locally

    ReplyDelete
    Replies
    1. Hi ,
      If you have added sql db in app_data folder then you don't need sql management studio . You can just specify connection string in following format: Server=.\SQLExpress;AttachDbFilename=|DataDirectory|mydbfile.mdf;Database=dbname;
      Trusted_Connection=Yes;

      Delete
  2. Howdy, My publish dialog (Vs2012, ASP.NET 4.5.1) looks nothing like your example. Could it be different for a "Web Site" than a "Web Application"? You are not specific...

    First step on my publish is to "Select or import a publish profile"....

    Regards

    Rob

    ReplyDelete
    Replies
    1. Hello Mr. Rob,
      This tutorial is to publish website in Visual studio 2012 , But your are trying to publish web application . To publish web application follow another article on this website:
      Publish web application in visual studio 2012

      Delete