This is a migrated thread and some comments may be shown as answers.

MultilIne text Problem in different browsers

2 Answers 38 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Lalu
Top achievements
Rank 1
Lalu asked on 14 Jun 2013, 09:57 AM
Hi,
Multiline textbox with maximum length is working in latest version of telerik but i have occurred a problem.Set maximum length in multiline textbox as 10  and enter the text as below

aaa
bbb
cc

after entering value check length of the textbox text ,It shows 12.This problem occurs in Mozilla and in IE.But it is working fine in chrome.I got a reply for this problem.

Telerik.Web.UI.RadInputControl.prototype._escapeNewLineChars_org = Telerik.Web.UI.RadInputControl.prototype._escapeNewLineChars;
Telerik.Web.UI.RadInputControl.prototype._escapeNewLineChars = function (text, replaceWith)
{
 return this._escapeNewLineChars_org(text, "  ");
}


Can i set this property dynamically from server side,becuase i have to create custom control based on multiline text box.So i cant include these script in each page.Expecting a fast reply from you.
Thanks
Shibin

2 Answers, 1 is accepted

Sort by
0
Viktor Tachev
Telerik team
answered on 19 Jun 2013, 08:23 AM
Hello Shibin,

Currently different browsers and browser versions are using different number of characters for new line. The RadTextBox takes this difference into account and on the server the new line is always counted as two characters. However this is not always so on the client side. Because of this, the fix you have should be implemented on the client. This way the behavior of the RadTextBox would be consistent in all browsers.

The developers are aware of this issue and a fix will be implemented as soon as possible. You could follow the status of the issue here.

I hope this information would be useful to you.

Regards,
Viktor Tachev
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
0
Lalu
Top achievements
Rank 1
answered on 19 Jun 2013, 10:56 AM
Thanks for working on this issue.
Tags
Ajax
Asked by
Lalu
Top achievements
Rank 1
Answers by
Viktor Tachev
Telerik team
Lalu
Top achievements
Rank 1
Share this question
or