8:54 am Wednesday, August 20, 2008


  Navigation
  Help?
Contact Aaron for all inquiries.
 

  News

ASP Inline Calendar 3.9 Beta 1
ASP Games
ASP Inline Corporate Calendar 3.8 BETA 1 Demo
Calendar Updates
 

A Better World By Design
 
 
AaronOutpost : ASP / Tutorials / Programmers Etiquette

Aaron's Programmers Etiquette
By: Aaron B. Copyright AaronOutpost.com

What is Aaron's Programmers Etiquette? Basically, just my list of tips on programming and how to help you in while you learn to program and create crisp and clear coding.

  1. Dimension Everything! This is a major argument to some, because some people just want to use the "Set" command not have to Dimension a variable. I think it is important to dimension all variables and list them so it becomes easy reference when they are in one or two clustered areas instead of spread out through the page, and that bring to me #2.
     

  2. Comment All Variables This goes along with #1, not only should you keep all variables in similar areas but you should also add a comment after each variable so you know exactly what you set that variable there for. This way if you go back to work on the script later you don't have to look throughout the script to figure out what a certain variable is.
    Example:  The comment is the green text after the apostrophe mark '

              Dim my_variable         
     
    'Holds the Database Connection Object
     

  3. Close the recordset Always close the recordset for server maintenance.
     

  4. Reset server objects Always reset server objects for server maintenance and to help keep scripts from getting mixed data.

    I call 3 & 4 combined CRC because you should do at the end of each page of a script. Stands for Close, Reset, Close.
    Close the recordset
    Reset the server objects
    Close the ASP scripting tag and HTML

 


AaronOutpost : ASP / Tutorials / Programmers Etiquette

Aaron Outpost West Virginia, USA A Mark of _-Squire-_ Creations Inc.  CopyrightŠ 2005 All Rights Reserved