5.2.4.3 Event Declaration

 event-declaration = ["Public"]
 "Event" IDENTIFIER [event-parameter-list] 
 event-parameter-list = "(" [positional-parameters] ")" 

Static Semantics

  • An <event-declaration> defines an event member of the class defined by the enclosing class module.

  • An <event-declaration> that does not begin with the keyword (section 3.3.5.1) Public has the same meaning as if the keyword Public was present.

  • The event name of the event member is the name value of the <IDENTIFIER>.

  • Each <event-declaration> within a class-module-declaration-section MUST specify a different event name.

  • An event name can have the same name value as a module variable name, module constant name, enum member name, or procedure name that is defined within the same module.

  • The name of an event MUST NOT contain any underscore characters (Unicode u+005F).

  • Runtime Semantics

  • Any <positional-param> elements contained in an <event-parameter-list> do not define any variables or variable bindings. They simply describe the arguments that MUST be provided to a <raiseevent-statement> that references the associated event name.