IToolboxItemInfo::Icon Property

 

Gets the icon for the toolbox item as a file path, byte array, Bitmap, or IntPtr.

Namespace:   Microsoft.VisualStudio.Shell
Assembly:  Microsoft.VisualStudio.Shell.Immutable.11.0 (in Microsoft.VisualStudio.Shell.Immutable.11.0.dll)

property Object^ Icon {
	Object^ get();
}

Property Value

Type: System::Object^

This value can be any of the following, in order of decreasing efficiency (that is, you should prefer the lower-numbered options):

  1. The path to an image file (as a string).

  2. A byte array containing the bytes of an image file.

  3. A Bitmap object.

  4. A Win32 GDI bitmap handle (as an IntPtr).

For the file path and byte array, all GDI+ file types are supported: BMP, GIF, JPG, PNG and TIFF.

This property can be accessed on a background thread.

Return to top
Show: