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

RadNumericTextBoxes generate thousands LOC (Js)

1 Answer 55 Views
Input
This is a migrated thread and some comments may be shown as answers.
Markus Greuel
Top achievements
Rank 1
Markus Greuel asked on 29 Mar 2010, 12:53 PM
HI,

I have a table which may contain hundreds of NumericTextBoxes. This results in thousands line of Javascript repeating

Sys.Application.add_init(function() {
    $create(Telerik.Web.UI.RadNumericTextBox, {"_enableOldBoxModel":false,"_focused":false,"_originalValue":45,"_postBackEventReferenceScript":"setTimeout(\"__doPostBack(\\\u0027ctl00$m$g_c2c9bd70_6add_41ce_811f_7a6842bf9330$ctl10$6cd603ba-6163-4442-b414-0171c5db5942_upper_12$inputBox\\\u0027,\\\u0027\\\u0027)\", 0)","_shouldResetWidthInPixels":true,"clientStateFieldID":"ctl00_m_g_c2c9bd70_6add_41ce_811f_7a6842bf9330_ctl10_6cd603ba-6163-4442-b414-0171c5db5942_upper_12_inputBox_ClientState","enabled":true,"incrementSettings":{InterceptArrowKeys:true,InterceptMouseWheel:true,Step:1},"numberFormat":{"DecimalDigits":0,"DecimalSeparator":".","CultureNativeDecimalSeparator":".","GroupSeparator":",","GroupSizes":3,"NegativePattern":"-n","NegativeSign":"-","PositivePattern":"n","AllowRounding":true,"KeepNotRoundedValue":false,"KeepTrailingZerosOnFocus":false},"styles":{HoveredStyle: ["width:32px;", "riTextBox riHover eingabe number"],InvalidStyle: ["width:32px;", "riTextBox riError eingabe number"],DisabledStyle: ["width:32px;", "riTextBox riDisabled eingabe number"],FocusedStyle: ["width:32px;", "riTextBox riFocused eingabe number"],EmptyMessageStyle: ["width:32px;", "riTextBox riEmpty eingabe number"],ReadOnlyStyle: ["width:32px;", "riTextBox riRead eingabe number"],EnabledStyle: ["width:32px;", "riTextBox riEnabled eingabe number"],NegativeStyle: ["width:32px;", "riTextBox riNegative eingabe number"]}}, null, null, $get("ctl00_m_g_c2c9bd70_6add_41ce_811f_7a6842bf9330_ctl10_6cd603ba-6163-4442-b414-0171c5db5942_upper_12_inputBox"));
});

As the application targets IE6 this is extremly slow, causing a non responding IE.

Isn't there a possibility to speed things up / reduce the js code?

1 Answer, 1 is accepted

Sort by
0
Accepted
Dimo
Telerik team
answered on 29 Mar 2010, 02:21 PM
Hello Markus,

Yes,  use RadInputManager instead.

http://www.telerik.com/help/aspnet-ajax/introduction_to_radinputmanager.html

http://demos.telerik.com/aspnet-ajax/input/examples/radinputmanager/firstlook/defaultcs.aspx

Kind regards,
Dimo
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Tags
Input
Asked by
Markus Greuel
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Share this question
or