Is Calling Functions In ASP Efficient?

Results 1 to 4 of 4

Thread: Is Calling Functions In ASP Efficient?

  1. #1
    Jim Beauchamp Guest

    Default Is Calling Functions In ASP Efficient?

    I read somewhere you shouldn&#039t use functions in asp code<BR>unless you call perform a specific function when processing<BR>records over and over. This article said using functions<BR>slows down the processing of ASP pages. Is this true?<BR>If so, does anyone know where the article is on the web<BR>I&#039ve search this web site, asplearn and asptoday with no luck<BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: Is Calling Functions In ASP Efficient?

    Here is an article that sounds like what you where looking for...<BR>Enhancing Performance in ASP <BR><BR><BR>Calling functions IS efficient, but what you do<BR>in your function may not be. This article uses<BR>response.write as an example.<BR>

  3. #3
    Join Date
    Dec 1969

    Default If it's not, it's worth it anyway

    I wouldn&#039t dream of doing any kind of programming without breaking it up into functions. Unless it were a really, really simple app.<BR><BR>Functions make your code a LOT easier to read, and thus easier to maintain. They also make code reuse a lot easier and useful, not to mention debugging.<BR><BR>I currently support an app that was written half in functions, and half "straight through." I just finished rewriting the "straight through" part into functions. It&#039s amazing - I can actually make sense of the app now. It&#039s also cleaner, error checking is improved by use of the functions, and it actually appears FASTER to the end-user.<BR><BR>If functions slow the app down, the benefits more than make up for it.

  4. #4
    Ian Stallings Guest

    Default my two cents

    I just wanted to add something - using functions in ASP also allows you to encapsulate your code and at a later date you can place the code into a VB object - If, when you wrote it, you kept in mind that the function might be used in a compiled state and removed any ASP intrinsics like Session objects, etc.<BR><BR>I hope this helps some- <BR>Ian S

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts