Difference between WebSite and Web Project...and conversion from WebSite to WebProjec

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • bharathreddy
    New Member
    • Aug 2006
    • 116

    Difference between WebSite and Web Project...and conversion from WebSite to WebProjec

    I was new to VS 2008. I was doing a project basically it was web application, so i created website with out knowing the inner lying methodology used. Then at the end of project when I tried to build the application it was like creating differennt project dlls, then I came to know we cannot create a single project dll from website application.

    What to know the difference bewteen website and webproject ...read this article its simple and sweet...
    http://www.dotnetspide r.com/resources/1520-Difference-between-web-site-web-application.asp x

    So I thought of moving/converting the project WebSite to WebApplication project which can be done. Then what I did is like created a new web project and added all the code files to this project, then right clicked on the project, we find "Convert to Web Application" which actually does the conversion process. But it may not do it completely. If it does then its ok but if it dosen't don;t panic there are ways to get it working.

    Some points that are very common:
    1) You can also declare the controls in the "Page_File.aspx .designer.cs" file, the controls which are not created while converting from website to web application, and that should work as well.

    2) When you build the application and then publish the site into iis. And when you try to access the site if it throws error message saying no .cs file, then probably codefile should be change to codebehind which points to the code behind file for that page.

    Refer:
    1) http://msdn.microsoft. com/en-us/library/aa983476(VS.80) .aspx
    2) http://gurustop.net/blog/2008/08/03/converting-vs-2008-website-to-web-application/
  • tlhintoq
    Recognized Expert Specialist
    • Mar 2008
    • 3532

    #2
    May I suggest:
    • Correcting various mistakes such as " Don;t " and " differennt "
    • Making the URL's clickable links.
    • Making a follow-up article that is more of a "Let's do it correctly, from the start", and less of a historical look back at how it was done wrong and having to be fixed.


    I think it is great to have an article explaining the details of how to fix a bad situation, because we all get into them. But it's really nice if we can guide new users along the correct path from the start of their project whenever possible.

    Comment

    • Frinavale
      Recognized Expert Expert
      • Oct 2006
      • 9749

      #3
      I moved this article to the writing room.
      bharathreddy, could you please clean this up a bit so that we can move it back to the articles section?

      -Frinny

      Comment

      • bharathreddy
        New Member
        • Aug 2006
        • 116

        #4
        [QUOTE=bharathre ddy;3564271]

        Conversion from WebSite application to WebProject is very simple and easy way. Difference bewteen website and webproject, read this article its simple and sweet...


        Simple note is :
        if you want your application to generate a single dll for your entire project then you have to create a web project instead of web site which creates singel dll per page.

        Converting the project WebSite to WebApplication project which can be done by rightclicking on the project and click on "Convert to Web Application" which actually does the conversion process. But it may not do it completely. If it does then its ok but if it dosen't don't panic there are ways to get it working.

        Some points that are very common:
        1) You can also declare the controls in the "Page_File.aspx .designer.cs" file, the controls which are not created while converting from website to web application, and that should work as well.

        2) When you build the application and then publish the site into iis. And when you try to access the site if it throws error message saying no .cs file, then probably codefile should be change to codebehind which points to the code behind file for that page.

        Refer:
        1) http://msdn.microsoft.com/en-us/libr...76(VS.80).aspx

        2) http://gurustop.net/blog/2008/08/03/...eb-application

        Comment

        Working...