ProjectBeforeResourceNew Event

Occurs before one or more resources are created.

Syntax

Private Sub object**_ProjectBeforeResourceNew(ByVal** pj As MSProject.Project, Cancel As Boolean)

object     An object of type Application declared with events in a class module. For more information, see Using events with the Application object.

pj     The project in which the resource or resources are being created.

Cancel     False when the event occurs. If the event procedure sets this argument to True, the new resource or resources are not created.

Remarks

Project events do not occur when the project is embedded in another document or application.

The ProjectBeforeResourceNew event doesn't occur during resource pool operations, when inserting or removing a subproject, or when changes have been made using a custom form.

Applies to | Application Object

See Also | ProjectBeforeAssignmentNew Event | ProjectBeforeResourceChange Event | ProjectBeforeResourceDelete Event | ProjectBeforeResourceNew2 Event | ProjectBeforeTaskNew Event