TypeDescriptor.GetEditor TypeDescriptor.GetEditor TypeDescriptor.GetEditor TypeDescriptor.GetEditor Method

Definition

Returns an editor with the specified base type.

Overloads

GetEditor(Object, Type) GetEditor(Object, Type) GetEditor(Object, Type) GetEditor(Object, Type)

Gets an editor with the specified base type for the specified component.

GetEditor(Type, Type) GetEditor(Type, Type) GetEditor(Type, Type)

Returns an editor with the specified base type for the specified type.

GetEditor(Object, Type, Boolean) GetEditor(Object, Type, Boolean) GetEditor(Object, Type, Boolean) GetEditor(Object, Type, Boolean)

Returns an editor with the specified base type and with a custom type descriptor for the specified component.

GetEditor(Object, Type) GetEditor(Object, Type) GetEditor(Object, Type) GetEditor(Object, Type)

Gets an editor with the specified base type for the specified component.

public:
 static System::Object ^ GetEditor(System::Object ^ component, Type ^ editorBaseType);
public static object GetEditor (object component, Type editorBaseType);
static member GetEditor : obj * Type -> obj
Public Shared Function GetEditor (component As Object, editorBaseType As Type) As Object

Parameters

component
Object Object Object Object

The component to get the editor for.

editorBaseType
Type Type Type Type

A Type that represents the base type of the editor you want to find.

Returns

An instance of the editor that can be cast to the specified editor type, or null if no editor of the requested type can be found.

Exceptions

Remarks

The type of editorBaseType is usually UITypeEditor, but you can also use other types (for example, ComponentEditor and InstanceCreationEditor).

You can define multiple editors for a property. You use this method to select the editor you want to use.

See Also

GetEditor(Type, Type) GetEditor(Type, Type) GetEditor(Type, Type)

Returns an editor with the specified base type for the specified type.

public:
 static System::Object ^ GetEditor(Type ^ type, Type ^ editorBaseType);
public static object GetEditor (Type type, Type editorBaseType);
static member GetEditor : Type * Type -> obj

Parameters

type
Type Type Type Type

The Type of the target component.

editorBaseType
Type Type Type Type

A Type that represents the base type of the editor you are trying to find.

Returns

An instance of the editor object that can be cast to the given base type, or null if no editor of the requested type can be found.

Exceptions

Remarks

The type of editorBaseType is usually UITypeEditor, but you can also use other types (for example ComponentEditor and InstanceCreationEditor).

You can define multiple editors for a type. You use this method to select the one you want to use.

Call this version of this method only when you do not have an instance of the object.

See Also

GetEditor(Object, Type, Boolean) GetEditor(Object, Type, Boolean) GetEditor(Object, Type, Boolean) GetEditor(Object, Type, Boolean)

Returns an editor with the specified base type and with a custom type descriptor for the specified component.

public:
 static System::Object ^ GetEditor(System::Object ^ component, Type ^ editorBaseType, bool noCustomTypeDesc);
public static object GetEditor (object component, Type editorBaseType, bool noCustomTypeDesc);
static member GetEditor : obj * Type * bool -> obj
Public Shared Function GetEditor (component As Object, editorBaseType As Type, noCustomTypeDesc As Boolean) As Object

Parameters

component
Object Object Object Object

The component to get the editor for.

editorBaseType
Type Type Type Type

A Type that represents the base type of the editor you want to find.

noCustomTypeDesc
Boolean Boolean Boolean Boolean

A flag indicating whether custom type description information should be considered.

Returns

An instance of the editor that can be cast to the specified editor type, or null if no editor of the requested type can be found.

Exceptions

Remarks

The type of editorBaseType is usually UITypeEditor, but you can also use other types (for example ComponentEditor and InstanceCreationEditor).

You can define multiple editors for a property. You use this method to select the editor you want to use.

See Also

Applies to