public/private subs and functions

Results 1 to 2 of 2

Thread: public/private subs and functions

  1. #1
    Dano Guest

    Default public/private subs and functions

    What are the (dis)advantages of declaring your subs and functions public and private? How does this affect performance (or does it)?<BR><BR>My intuition tells me that declaring a sub/func private reduces an unneccessary read from the web server. But at the same time it must be "compiled" by ASP before it executes?

  2. #2 Guest

    Default RE: public/private subs and functions

    Private and Public Subs/Functions are a wash in ASP because Private and Public have file scope anyway. You cannot call a function that is public from one ASP page that is in another ... so Public serves no real purpose. This is probably a carryover from VBA.<BR><BR>The only time this will matter is during the creation of scriptlets I imagine.

Posting Permissions

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