PDA

View Full Version : [CLOSED] Preserve literals in Grid Inline Editing?



aditya
May 15, 2014, 4:10 PM
Hi,
I am using Grid inline editing.
1. My problem is when i put 2-3 spaces continues in inline editing, it shows 2-3 spaces properly in editing mode but when after 'afteredit event' it shows only single space in cell.
2. like this i have another problem when we put some html tags in cell while editing its behavior changed.
how to preserve literals as user enter it.

Daniil
May 16, 2014, 5:03 AM
Hi @aditya,

Please use the following Renderer.

<ext:Column runat="server" Text="Test" DataIndex="test">
<Renderer Handler="value = Ext.util.Format.htmlEncode(value);
return value.replace(/ /g, '&nbsp;');" />
<Editor>
<ext:TextField runat="server" />
</Editor>
</ext:Column>

aditya
May 17, 2014, 6:50 PM
Thanks @Daniil, This worked. Please close this thread.