CodeStruct2::AddEvent Method (String^, String^, Boolean, Object^, vsCMAccess)

 

Adds a struct event.

Namespace:   EnvDTE80
Assembly:  EnvDTE80 (in EnvDTE80.dll)

CodeEvent^ AddEvent(
	String^ Name,
	String^ FullDelegateName,
	bool CreatePropertyStyleEvent = false,
	Object^ Position,
	vsCMAccess Access = vsCMAccess::vsCMAccessDefault
)

Parameters

Name
Type: System::String^

Required. Name of the struct event to add.

FullDelegateName
Type: System::String^

Required. Name of the delegate to base the event on.

CreatePropertyStyleEvent
Type: System::Boolean

Optional. Creates an event that has a property style accessor.

Position
Type: System::Object^

Optional. Location of the event in code.

Access
Type: EnvDTE::vsCMAccess

Optional. A vsCMAccess constant.

Return Value

Type: EnvDTE80::CodeEvent^

Returns the struct event created.

System_CAPS_noteNote

The values of code model elements such as classes, structs, functions, attributes, delegates, and so forth can be non-deterministic after making certain kinds of edits, meaning that their values cannot be relied upon to always remain the same.

Return to top
Show: