Pasos específicos para escribir ColorRamp basado en el motor ArcGIS y representar valores únicos (para capas de entidades universales)
{
IFeatureSelection R_pFeatureSelection = R_pFeatureLayer como IFeatureSelection
IFeature R_pFeature
IFeatureCursor R_FeatureCursor; /p>
R_pFeatureSelection = R_pFeatureLayer como IFeatureSelection;
R_pFeatureSelection.clear();
ISelectionSet R_pSelectionSet = R_pFeatureSelection.
rx.MaxSaturation = 30;
rx.MinValue = 85;
rx.MaxValue = 100;
rx.StartHue = 0; 360;
rx.Size = 100;
bool ok;;
rx.CreateRamp(out ok);
IEnumColors RColors = rx.Colors;
RColors.Reset();
while (R_pFeature ! = null)
{
ISimpleFillSymbol symd = new SimpleFillSymbolClass();
symd.Style = esriSimpleFillStyle.esriSFSSolid;
symd.Outline.Width = 1;
symd.Color = RColors.Next( );
cadena valorestr = R_pFeature.get_Value(index).ToString();
renderizador .AddValue(valorestr, valorestr, symd como ISymbol
); R_pFeature = R_FeatureCursor.NextFeature();
}
IGeoFeatureLayer geoLayer = R_pFeatureLayer como IGeoFeatureLayer;
geoLayer.Renderer = renderizador como IFeatureRenderer;
axMap.Refresh();
}
R_pFeature = R_FeatureCursor.