Applying Attributes Multiple Times
According to the particular nature of your custom attributes, you can decide whether multiple instances can be applied to programming elements. This is accomplished by setting the AllowMultiple
property as True
in the AttributeUsage
. The following is an example:
Notice that AllowMultiple
is optional and thus is invoked as a named parameter. The following is an example on how you apply multiple instances of an attribute:
In the particular example of the DocumentProperties
attribute, multiple instances probably ...
Get Visual Basic® 2010 Unleashed now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.