Last post Aug 22, 2008 07:20 AM by paudirac
Aug 21, 2008 02:46 PM|paudirac|LINK
I'm trying to customize some controls at design-time (and I'm not able to persist all customizations in the aspx file). I use a custom DataBindingHandler in a control. When DataBindControl method is called I use the binding expression to customize my controls:
I set some properties according to the expression and information I can get from the DataSet.
I would like that the properties that I set for the control will be persisted in the aspx file in order not to lose the customizations. To set the properties I use a TypeDescriptor and I call IComponentChangeService.OnComponentChanged after setting them.
This results in the component being updated in the design surface and the property being updated in the property browser, but nothing is serialized in the aspx file. I am surely missing something, but I don't know what. I was convinced that IComponentChangeService.OnComponentChanged
would fire the serialization.
I'm also setting some properties of other controls that I access by means of the IReferenceService.
Any help would be appreciated. Thank you very much,
design Time aspx persistence
Aug 22, 2008 07:20 AM|paudirac|LINK
Another way to say what I mean. Could I "simulate" through code (in a desiner control) something like a user manually setting the Text property of a TextBox in the property browser? (Which will cause the value to be serialized in the aspx file.) Can I do
this from the designer of another Control?