This document is archived and information here might be outdated.  Recommended version.


ISymbologyStyleClass.AddItem Method (ArcObjects .NET 10.8 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Controls > ESRI ArcGIS Controls > Interfaces > IS > ISymbologyStyleClass Interface > ISymbologyStyleClass.AddItem Method
ArcGIS Developer Help

ISymbologyStyleClass.AddItem Method

Adds an item to the SymbologyStyleClass.

[Visual Basic .NET]
Public Sub AddItem ( _
    ByVal item As IStyleGalleryItem, _
    [ByVal index As Integer] _
)
[C#]
public void AddItem (
    IStyleGalleryItem item,
    int index
);
[C++]
HRESULT AddItem(
  IStyleGalleryItem* item,
  long index
);
[C++]
Parameters
item [in]

item is a parameter of type IStyleGalleryItem* index [in, optional, defaultvalue()]
index is a parameter of type long

Product Availability

Available with ArcGIS Engine.

Description

Adds the specified item to the SymbologyStyleClass at the specified index. By default the index is -1 and represents the end of the item collection. Specify the item as a ServerStyleGalleryItem.

Errors Returned

1023 800a03ff: The specified index is out of range
1078 800a0436: The specified item is not recognized as a valid symbology
1079 800a0436: The style class of the symbology supplied does not match that of the SymbologyStyleClass

See Also

ISymbologyStyleClass Interface

.NET Samples

Controls commands environment Update a frame's background, border, and shadow using the SymbologyControl Change layer rendering using the SymbologyControl