Problem with TypeConverter attributes in the "UserControl TestContainer" window.

Hi all, I have a user control that has some custom properties that should show the “%” at the end of the value in the design time so I created a converter class called “PercentageConverter” that inherits from “TypeConverter” class. This class should work exactly as the System OpacityConverter class but for some reason the properties with this converter class are blacked out in the “UserControl TestContainer”. Now, if I include this converter class in a Class Library project and then reference it in the “UserControl” project it works. It seems that the converter class should be outside of the UserControl project in order to show the properties formatted in the “UserControl TestContainer”.

Why is this happening? Is this a small bug in the “UserControl TestContainer” or should I add some attributes to the converter class so that it generates an instance when it is used with “TypeConverter” attribute on a property. I say generate an instance because when I click on the blacked out property it throws an exception saying “Object reference not set to an instance of an object."

Thanks in advance,

Arman G.

[1454 byte] By [VBDT] at [2008-1-9]
# 1

Interesting! No one knows about this problem?

VBDT at 2007-10-2 > top of Msdn Tech,Visual Basic,Visual Basic IDE...