Guidelines for naming Visual Basic procedures, variables, and constants

Microsoft Office Access 2003

Show All Show All

Guidelines for naming Visual Basic procedures, variables, and constants

Names of procedures, variables, and constants in your Microsoft Visual Basic for Applications code:

  • Can be up to 255 characters long.
  • Must begin with a letter.
  • Can include letters, numbers, or underscore characters (_).
  • Can't include punctuation characters or spaces.
  • Can't be a Visual Basic keyword. A keyword is a word that Visual Basic uses as part of its language. This includes predefined statements (such as If and Loop), functions (such as Len and Abs), and operators (such as Or and Mod).