Portal Engine
Version 3.x > Portal Engine > Set value of CMSEditableRegion View modes: 
User avatar
Member
Member
affandy - 2/4/2009 12:47:00 AM
   
Set value of CMSEditableRegion
I try to set value of CMSEditableRegion with this code :

CMSEditableRegion1.LoadContent("test", True)

But it raised error
"[CMSAbstractEditableControl.LoadContent]: This method must be overriden by the inherited class"

How to correct it


User avatar
Kentico Support
Kentico Support
kentico_jurajo - 2/4/2009 2:28:10 AM
   
RE:Set value of CMSEditableRegion
Hi,

You would need to use following code in OnPreRender method of your aspx template:

protected override void OnPreRender(EventArgs e)
{
base.OnPreRender(e);
this.MainContentText.LoadContent("some text");
}

where MainContentText is ID of your editable region control.


Best Regards,
Juraj Ondrus