NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

MemberAttributeCollection.All

Gets an array with the attributes for this collection.

[Visual Basic]
Overridable Public Property All As MemberAttribute ()
[C#]
public MemberAttribute[] All {virtual get; virtual set;}
[C++]
public: __property virtual MemberAttribute* get_All();
public: __property virtual void set_All(MemberAttribute*[]);
[JScript]
public function get All() : MemberAttribute[];
public function set All(MemberAttribute[]);

Property Value

An array of type MemberAttribute with the attributes for this collection.

Exceptions

Exception Type Condition
NotSupportedException Setting the property.

Remarks

This property is read-only. It will throw an exception if you try to set its value.

Notes to Inheritors: If you want to add to the collection, you must inherit from this class and implement set in this property.

Example [Visual Basic]

The following example shows how to get an array of type MemberAttribute using the All property. It assumes that Button1 has been instantiated on a form.

[Visual Basic]

Private Sub GetAllAttributes()
   'Create a new collection and assign it the attributes for Button1.
   Dim attributes As MemberAttributeCollection
   attributes = TypeDescriptor.GetAttributes(Button1)

   'Get all the MemberAttributes.
   Dim aArray() As MemberAttribute
   aArray = attributes.All

   'Print all the attributes in a text box.
   Dim i As Integer
   For i = 0 To aArray.Length - 1
      TextBox1.Text &= aArray(i).ToString & " "
   Next
End Sub

See Also

MemberAttributeCollection Class | MemberAttributeCollection Members | System.ComponentModel Namespace | MemberAttribute