Results 1 to 2 of 2

Thread: Sub's

  1. #1
    Join Date
    Dec 1969

    Default Sub's

    What is the deal with Sub&#039;s? Is it better to use them when you write asp script to keep it clean, or sub&#039;s should be used for a differnet things?<BR><BR>Thanks

  2. #2
    Join Date
    Dec 1969

    Default RE: Sub's

    A sub is different from a function in that a function returns a value and a sub doesnt.<BR><BR>You should use a sub when you have a block of code that you will be using more than once in the same script. <BR>For example inserting a recordset into a database....<BR><BR>Then you can contain it within a sub, reduce the size of your script and make it easier for other people (and yourself) to understand the code.

Posting Permissions

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