defaultcollelem

Wird für die Visual Basic-Codeoptimierung verwendet.

Syntax

[defaultcollelem]

Hinweise

Das defaultcollelem C++-Attribut weist die gleiche Funktionalität wie das defaultcollelem MIDL-Attribut auf.

Beispiel

Der folgende Code zeigt eine Schnittstellenmethode mit dem defaultcollelem-Attribut :

// cpp_attr_ref_defaultcollelem.cpp
// compile with: /LD
#include <unknwn.h>
[module(name="MyLib")];
[object, uuid("00000000-0000-0000-0000-000000000001")]
__interface IMyForm
{
   [propget, id(1), bindable, defaultcollelem, displaybind, defaultbind, requestedit] HRESULT P1([out, retval] long *nSize);
   [propput, id(1), bindable, defaultcollelem, displaybind, defaultbind, requestedit] HRESULT P1([in] long nSize);
};

Anforderungen

Attributkontext Wert
Gilt für Schnittstellenmethode
Wiederholbar Nein
Erforderliche Attribute None
Ungültige Attribute None

Weitere Informationen finden Sie unter Attributkontexte.

Siehe auch

IDL-Attribute
Methodenattribut