London Dev Meetup Rescheduled! Due to unavoidable reasons, the event has been moved to 21st May. Speakers remain the same—any changes will be communicated. Seats are limited—register here to secure your spot!
AI OnAI Off
London Dev Meetup Rescheduled! Due to unavoidable reasons, the event has been moved to 21st May. Speakers remain the same—any changes will be communicated. Seats are limited—register here to secure your spot!
Have you tried to set the default values on the local block through the shared block's SetDefaultValues?
Example:
public override void SetDefaultValues(ContentType contentType) { LocalBlock.PropertyOnLocalBlock = "value"; }
You probably know this, but also be aware of that SetDefaultValues only kicks in when creating the content type.
Yeah your suggestion does not work. But I did find a solution ... strangely enough this works:
public override void SetDefaultValues(ContentType contentType) { LocalBlock.Property["PropertyOnLocalBlock"].Value = "value"; }
Does not seem to work ... data specified is not set.
The local block is inside another shared block, and i can set default values on other properties on the shared block (just not the properties on the local blocks)