OK. So I figured out my problem partially. It was my typeconverter. I
was assuming that in my ConvertTo function, context and
context.instance would always produce values and therefore was only
converting if they did. It's kind of funny, actually. I always thought
that I would throw some kind of exception if I DIDN'T check those
values. That's irony for you.
So I got the name of the control to persist to my attribute the way I
want. My new problem is how to DEserialize it. When I view the webform
in the browser, it produces the exception:
Unable to generate code for a value of type 'TextEdit.Palette'. This
error occurred while trying to generate the property value for
Palette.
I suppose I understand this. It's trying to generate a palette from
scratch from the value in the attribute, not the reference to the
object.
How would I approach DEserializing this object as a refernce to
another control on the webform?
|