DLLs & ASP.Net

Posted on 2011-10-19
Last Modified: 2012-06-27
What are the pros and cons of compiling code to a DLL to be used in an ASP.Net application?
Question by:rgturner
    LVL 20

    Accepted Solution

    I can only think of 3 pros and 1 con. I'm sure I could google more but heck so could you so Im thinking you're looking for what's in people's heads...

    1. Pre-compiling makes the server run faster initially.


    Even if you don't pre-compile your .aspx pages into .dll's the server will compile them for you the 1st time someone tries to open a page. They then remain compiled (virtually) for the length the server session stays alive.

    It amounts to the same way it takes longer the 1st time you debug a solution in VS vs just refreshing the same debug session. Next time you put up a site, or even change a page, go to the site and note on the 1st load everything takes a little longer... it's compiling.

    2. If you pre-compile you will never crash your site due to some faulty code that wont compile. This is a small matter and certainly there are various other ways you might crash your site with code that is already compiled :)

    3. Security! No one will be able to see or change your code except those you give access to the original code base (well not technically anyway). You can even put up code for people who haven't paid you yet with the reasonable assertion that they wont steal your work and go out of business so easily, etc.


    1. Its a little more work to keep track and maintain things. I wouldn't even say "more" so much as "different".

    That's my .02

    Author Closing Comment

    Thanks for your .02!

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Highfive Gives IT Their Time Back

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    It’s quite interesting for me as I worked with Excel using for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
    IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
    Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

    759 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    11 Experts available now in Live!

    Get 1:1 Help Now