[]
Gets the IColorStop object at the specified index in the collection.
IColorStop this[int index] { get; }
ReadOnly Default Property Item(index As Integer) As IColorStop
| Type | Name | Description |
|---|---|---|
| int | index | The zero-based index of the gradient stop in the collection. |
IRange range = worksheet.Range["A1"];
range.Interior.Pattern = Pattern.LinearGradient;
ILinearGradient gradient = (ILinearGradient) range.Interior.Gradient;
IColorStops colorStops = gradient.ColorStops;
IColorStop startStop = colorStops[0];
startStop.Color = Color.Red;
IColorStop endStop = colorStops[1];
endStop.Color = Color.Blue;