G
Guest
I am working on a custom DataGridColumnStyle that can host a UserControl. I
have created a public property on this ColumnStyle of type MyUserControlBase.
I would like to be able to set this property in the PropertyGrid by choosing
from a list of UserControls that inherit from MyUserControlBase.
Using a TypeConverter that inherits from TypeList Converter, I have been
able to get the property to show up in the PropertyGrid and I can even get
the drop-down list to show the list of UserControls. But when I select one
of them, I get a designtime error of "Invalid property value - Object type
cannot be converted to target type." I have tried numerous combinations of
overriding CanConvertFrom/ConvertFrom & CanConvertTo/ConvertTo without
success.
Can someone give me a push in the right direction? Thanks.
Tony
have created a public property on this ColumnStyle of type MyUserControlBase.
I would like to be able to set this property in the PropertyGrid by choosing
from a list of UserControls that inherit from MyUserControlBase.
Using a TypeConverter that inherits from TypeList Converter, I have been
able to get the property to show up in the PropertyGrid and I can even get
the drop-down list to show the list of UserControls. But when I select one
of them, I get a designtime error of "Invalid property value - Object type
cannot be converted to target type." I have tried numerous combinations of
overriding CanConvertFrom/ConvertFrom & CanConvertTo/ConvertTo without
success.
Can someone give me a push in the right direction? Thanks.
Tony