Thanks, unfortunately that post doesn't address my issue. I can change page properties in the OnPageSaving event without issue, its the properties belonging to dynamic content controls within page properties that I'm having issues with - and I suspect its due to how these dynamic content controls maintain their state.
foreach(var a in html.Fragments)
if(a is DynamicContentFragment)
var x = a as DynamicContentFragment;
var y = x.GetEditFormat();
x.DynamicContent.Properties["PropertyName"] = "something else";
var z = x.GetEditFormat();
// The issue is that y & z are the same.
I am trying to change property values for a dynamic content control in the OnSavingPage event. I iterate through the DynamicContentFragemnts of a PropertyXhtml property and am able to access the properties I'm looking for. However changing them doesn't seem to have an effect. I've even rebuilt the full Xhtml property using the fragments I'm iterating through but the dynamiccontent control seems to render the same markup (using GetEditFormat function) after I've changed the properties.
I've also used the DynamicContentControl's property's SaveData method but this doesn't seem to work either. I suspect its something quite obvious I'm missing!
Has anyone tried this successfully before or have any ideas?