I use a PropertyGrid in my UI. I had a property of type image, and the prop
grid popped up an open file dialog where the user could select an image,
then display a tiny thumbnail of it, along with the image type.
I've had to change the type of this property to a new class of my own, which
will still contain an image, but I need to handle opening the image myself.
So now, in the prop grid, I just get a grayed out string with my classes
name in it.
I would really like to make the property grid behave like it did when the
property was of type Image. I've been looking at TypeConverter, and such in
MSDN, and I'm very confused.
Basically, I want the user to click the ellipsis button, and see the open
file dialog, select a file of a type supported by the Image class, but take
in the filename from the dialog, do my own thing with it, and then show the
thumbnail with the image type in the property grid just like any other
property of type Image.
I know is that I've got to make a type converter, but I've almost no idea
what to put in the class, or how this whole thing will work, or even if it's
possible!
Any ideas WELL appreciated,
Eric