ColorConverter.CanConvertFrom(ITypeDescriptorContext, Type) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Détermine si ce convertisseur peut convertir un objet dans le type source donné en type natif du convertisseur.
public:
override bool CanConvertFrom(System::ComponentModel::ITypeDescriptorContext ^ context, Type ^ sourceType);
public override bool CanConvertFrom(System.ComponentModel.ITypeDescriptorContext context, Type sourceType);
override this.CanConvertFrom : System.ComponentModel.ITypeDescriptorContext * Type -> bool
Public Overrides Function CanConvertFrom (context As ITypeDescriptorContext, sourceType As Type) As Boolean
Paramètres
- context
- ITypeDescriptorContext
Qui ITypeDescriptorContext fournit un contexte de format. Vous pouvez utiliser cet objet pour obtenir des informations supplémentaires sur l’environnement à partir duquel ce convertisseur est appelé.
- sourceType
- Type
Type à partir duquel vous souhaitez effectuer la conversion.
Retours
true si cet objet peut effectuer la conversion ; sinon, false.