TypeConverter.ConvertFrom String to String
Posted
by Ken
on Stack Overflow
See other posts from Stack Overflow
or by Ken
Published on 2010-03-30T15:31:29Z
Indexed on
2010/03/30
15:33 UTC
Read the original article
Hit count: 321
typeconverter
I'm using a PropertyGrid to display a property. For one property, I'm displaying strings in a drop-down combobox. The displayed text of the property and the value of the property are both strings, but their text is different. The displayed text is friendly, the value text corresponds to a registry key name. I've created a TypeConverter to convert between the display text and the value text, but the ConvertFrom() method appears to work correctly until I change the combo-box selection. It then sends the 'value' text instead of the display text to use during the conversion.
Has anyone else used string-to-string conversion successfully?
© Stack Overflow or respective owner