<compilation defaultLanguage="c#" debug="true">

Discussion in 'ASP .Net' started by Alexander Walker, Feb 26, 2006.

  1. Hello

    I have recently published a web application using the "Publish Web Site" option
    of the solution explorer from Visual Studio 2005, I have published the website
    so that the pages could not be updated, do I need to set the web.config so that
    it contains <compilation defaultLanguage="c#" debug="false"> before I publish
    the web site or can I make this configuration change on the deployment machine
    after the site has been deployed?

    Thanks

    Alex
    Alexander Walker, Feb 26, 2006
    #1
    1. Advertising

  2. Hi Alex,

    Thanks for posting.

    As for ASP.NET 2.0 web applications, the page's codebehind classes and
    other source files(in App_Code) and components(DataSet or localization
    resource) are dynamically compiled, and the build type (debug or release)
    is specified by the web.config's <compilation debug="xxx" /> attribute. And
    this is the same when we manually precompile the web application through
    aspnet_compiler tool. If use the "Publish WebSite" menu in VS 2005 ide, it
    will force a release build, however , if you choose the "updatalbe" option,
    at runtime our aspx pages's dynamic classes will still be compiled as the
    version specified in web.config file. The difference between "updatable"
    and "non-updatable" is that "updatable" make the web pages partially
    precompiled, there still require some dynamic compilation at runtime for
    each page. While "non-updatable" make a full precompilation so that pages
    do not need additional dynamic compilation at runtime.

    Therefore, it is always recommended that we change the <compilation
    debug="xxx" /> to the corretly value before we perform precompilation for
    deployment. In addition, here is a good web article discussing on this:

    #Debug and Release Builds in ASP.NET 2.0
    http://odetocode.com/Blogs/scott/archive/2005/11/15/2464.aspx

    Hope this helps.

    Regards,

    Steven Cheng
    Microsoft Online Support

    Get Secure! www.microsoft.com/security
    (This posting is provided "AS IS", with no warranties, and confers no
    rights.)
    Steven Cheng[MSFT], Feb 27, 2006
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. RonL
    Replies:
    0
    Views:
    735
  2. Siemel Naran

    Does true ^ true return false?

    Siemel Naran, Jun 17, 2004, in forum: C++
    Replies:
    19
    Views:
    660
    Chris Theis
    Jun 18, 2004
  3. Chip
    Replies:
    6
    Views:
    2,627
    E. Robert Tisdale
    Jan 8, 2005
  4. André
    Replies:
    3
    Views:
    1,574
  5. bdb112
    Replies:
    45
    Views:
    1,334
    jazbees
    Apr 29, 2009
Loading...

Share This Page