Function...End Function (statement)

Procedure

  1. Must start with a letter.
  2. May contain letters, digits, and the underscore character ( _ ). Punctuation and type-declaration characters are not allowed.
    The exclamation point ( ! ) can appear within the name as long as it is not the last character, in which case it is interpreted as a type-declaration character.
  3. Must not exceed 80 characters in length.
  4. The call cannot end with a comma. For instance, using the above example, the following is not valid:
        a = Test(1,,)
  5. The call must contain the minimum number of parameters as required by the called function. For instance, using the above example, the following are invalid:
        a = Test(,1)    'Only passes two out of three required parameters.
        a = Test(1,2)    'Only passes two out of three required parameters.