Hi,
I Have a RadEditor inside a RadGrid ItemTemplate like this:
<EditItemTemplate>
<telerik:RadEditor ID="descriptionEditor" Runat="server" EditModes="Design" Font-Size="X-Small" Height="300px" Skin="Sunset" Width="100%" Html='<%# Bind("description") %>' Font-Names="Segoe UI,Arial,sans-serif" >
But when i change the content while "editing", later in codebehind UpdateCommand event, i get the previous value of "desciption" and not the update one (see the codebehind below: If description is "aaa", and i edit to "bbb", the variable newdescription in the event is still "aaa".
protected void grid_UpdateCommand(object source, GridCommandEventArgs e)
{
if (e.CommandName == RadGrid.UpdateCommandName)
{
GridEditFormItem item = (GridEditFormItem)e.Item;
if (e.Item is GridEditFormItem)
{
RadEditor descriptionEditor = (RadEditor)item.FindControl("descriptionEditor");
string newDescription = descriptionEditor.GetHtml(EditorStripHtmlOptions.None);
onProgressReportGrid.Rebind();
}
}
}
Can you help me, please ?
Kind regards
I Have a RadEditor inside a RadGrid ItemTemplate like this:
<EditItemTemplate>
<telerik:RadEditor ID="descriptionEditor" Runat="server" EditModes="Design" Font-Size="X-Small" Height="300px" Skin="Sunset" Width="100%" Html='<%# Bind("description") %>' Font-Names="Segoe UI,Arial,sans-serif" >
But when i change the content while "editing", later in codebehind UpdateCommand event, i get the previous value of "desciption" and not the update one (see the codebehind below: If description is "aaa", and i edit to "bbb", the variable newdescription in the event is still "aaa".
protected void grid_UpdateCommand(object source, GridCommandEventArgs e)
{
if (e.CommandName == RadGrid.UpdateCommandName)
{
GridEditFormItem item = (GridEditFormItem)e.Item;
if (e.Item is GridEditFormItem)
{
RadEditor descriptionEditor = (RadEditor)item.FindControl("descriptionEditor");
string newDescription = descriptionEditor.GetHtml(EditorStripHtmlOptions.None);
onProgressReportGrid.Rebind();
}
}
}
Can you help me, please ?
Kind regards