既存の ImageList 内の Image を取得または設定します。
[C#] C# では、このプロパティは ImageList.ImageCollection クラスのインデクサになります。
Public Default Property Item( _
ByVal index As Integer _) As Image
[C#]
public Image this[intindex] {get; set;}
[C++]
public: __property Image* get_Item(intindex);public: __property void set_Item(intindex, Image*);
[JScript]
returnValue = ImageCollectionObject.Item(index);ImageCollectionObject.Item(index) = returnValue;またはreturnValue = ImageCollectionObject(index);ImageCollectionObject(index) = returnValue;
[JScript] JScript では、この型で定義されている既定のインデックス プロパティを使用することができます。しかし、独自のインデックス プロパティを明示的に定義することはできません。ただし、このクラスの expando 属性を指定すると、既定のインデックス プロパティが提供されます。提供されるインデックス プロパティの型は Object 型であり、インデックス型は String になります。
引数 [JScript]
- index
取得または設定するイメージのインデックス。
パラメータ [Visual Basic, C#, C++]
- index
取得または設定するイメージのインデックス。
プロパティ値
index で指定されている、リスト内のイメージ。
例外
例外の種類 | 条件 |
---|---|
ArgumentOutOfRangeException | インデックスが 0 未満であるか、または Count 以上です。 |
Exception | イメージの置換に失敗しました。 |
ArgumentNullException | 割り当てられたイメージが null 参照 (Visual Basic では Nothing) です。または Bitmap ではありません。 |
必要条件
プラットフォーム: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 ファミリ
参照
ImageList.ImageCollection クラス | ImageList.ImageCollection メンバ | System.Windows.Forms 名前空間