ToolboxBitmapAttribute::GetImage Method (Type^)

 

Gets the small Image associated with this ToolboxBitmapAttribute object.

Namespace:   System.Drawing
Assembly:  System.Drawing (in System.Drawing.dll)

public:
Image^ GetImage(
	Type^ type
)

Parameters

type
Type: System::Type^

If this ToolboxBitmapAttribute object does not already have a small image, this method searches for a bitmap resource in the assembly that defines the type specified by the type parameter. For example, if you pass typeof(ControlA) to the type parameter, then this method searches the assembly that defines ControlA.

Return Value

Type: System.Drawing::Image^

The small Image associated with this ToolboxBitmapAttribute object.

This method searches for a resource named namespace.classname.bmp, where namespace is the namespace containing the definition of the type specified by the type parameter. For example, suppose you pass typeof(ControlA) to the type parameter. If ControlA is in NamespaceA in AssemblyA.dll, then this method searches AssemblyA.dll for a resource named NamespaceA.ControlA.bmp.

.NET Framework
Available since 1.1
Return to top
Show: