CodeDirectiveCollection.Add(CodeDirective) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Adds the specified CodeDirective object to the collection.
public:
int Add(System::CodeDom::CodeDirective ^ value);
public int Add (System.CodeDom.CodeDirective value);
member this.Add : System.CodeDom.CodeDirective -> int
Public Function Add (value As CodeDirective) As Integer
Parameters
- value
- CodeDirective
The CodeDirective object to add.
Returns
The index position at which the new element was inserted.
Examples
The following code example shows the use of the Add method to add a CodeDirective object to the collection. This example is part of a larger example provided for the CodeDirectiveCollection class.
// Adds a CodeDirective to the collection.
collection.Add(new CodeRegionDirective(CodeRegionMode.Start, "Region1"));
' Adds a CodeDirective to the collection.
collection.Add(New CodeRegionDirective(CodeRegionMode.Start, "Region1"))
Applies to
See also
Sodelujte z nami v storitvi GitHub
Vir za to vsebino najdete v storitvi GitHub, kjer lahko tudi ustvarite in pregledate težave in zahtevke za uveljavitev sprememb. Če želite več informacij, glejte naš vodnik za sodelavce.