I have found a really weird problem, and have given up trying to find how to answer this. MSDN and the windows forms programming book just don't explain this:
I have build a type converter that implements saving complex types through the InstanceDescriptor.
The class works without a problem generating code for the design mode until you run the program. Once run, the type converter is broken. It cannot convert and I get that darned stupid cryptic message "cannot convert [type a] to [type a]"
does anyone have any thoughts or suggestions on what is happening here?
-- modified at 21:54 Sunday 25th February, 2007
I messed around with a quick post i saw and found out that using casting in the type converters may cause crashes. I removed all of the casting and am now pulling the values from the object.
I also seem to be having trouble if i inherit from typeconverter, but have no problems from expandableobjectconverter
It works, but I'm really uncomfortable not being able to check a type prior to using it in the program. (granted it's only at design time) but still, I want to be able to do this.