RoutedEventConverter.ConvertFrom Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Attempts to convert the specified object to a RoutedEvent object, using the specified context.
public:
override System::Object ^ ConvertFrom(System::ComponentModel::ITypeDescriptorContext ^ typeDescriptorContext, System::Globalization::CultureInfo ^ cultureInfo, System::Object ^ source);
public override object ConvertFrom (System.ComponentModel.ITypeDescriptorContext typeDescriptorContext, System.Globalization.CultureInfo cultureInfo, object source);
override this.ConvertFrom : System.ComponentModel.ITypeDescriptorContext * System.Globalization.CultureInfo * obj -> obj
Public Overrides Function ConvertFrom (typeDescriptorContext As ITypeDescriptorContext, cultureInfo As CultureInfo, source As Object) As Object
Parameters
- typeDescriptorContext
- ITypeDescriptorContext
A format context that provides information about the environment from which this converter is being invoked.
- cultureInfo
- CultureInfo
Culture specific information.
- source
- Object
The object to convert.
Returns
The conversion result.
Exceptions
source
is not a string or cannot be converted.
Remarks
The RoutedEventConverter class only converts from String. Various techniques are employed in an attempt to obtain a result. typeDescriptorContext
is checked for various services including IXamlTypeResolver, IXamlSchemaContextProvider, and IAmbientProvider. The provided string is also checked against the internal list of WPF registered routed events on FrameworkElement. If all these attempts fail to resolve, NotSupportedException is thrown.
Applies to
Povratne informacije
https://aka.ms/ContentUserFeedback.
Stiže uskoro: Tijekom 2024. postupno ćemo ukinuti servis Problemi sa servisom GitHub kao mehanizam za povratne informacije za sadržaj i zamijeniti ga novim sustavom za povratne informacije. Dodatne informacije potražite u članku:Pošaljite i pogledajte povratne informacije za