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

RadNumericTextBox problem with decimal places

1 Answer 130 Views
Input
This is a migrated thread and some comments may be shown as answers.
Andrej
Top achievements
Rank 1
Andrej asked on 11 Feb 2014, 07:02 PM
Hi,

I have a problem with value change on RadNumericTextBox if textbox has decimal values. For example, if I have two textboxes on the form. On initial page load I initialize textbox 2 with value 10.5. After I change value on textbox 1 and press tab the value of textbox 2 changes to 105,00.

I have been experiencing the issue with controls version 2013.3.1324.35
I can not reproduce this issue with previous version I have been using: 2013.2.611.35

Here is the example:

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="Digits._Default" %>
 
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
        <Scripts>
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js">
            </asp:ScriptReference>
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js">
            </asp:ScriptReference>
            <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js">
            </asp:ScriptReference>
        </Scripts>
    </telerik:RadScriptManager>
    <telerik:RadNumericTextBox ID="RadNumericTextBox1" TabIndex="1" Culture="sl-SI" runat="server" AutoPostBack="true">
    </telerik:RadNumericTextBox>
    <br />
    <telerik:RadNumericTextBox ID="RadNumericTextBox2" runat="server" Culture="sl-SI" TabIndex="2" AutoPostBack="true">
    </telerik:RadNumericTextBox>
    </form>
</body>
</html>

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
 
namespace Digits
{
    public partial class _Default : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!Page.IsPostBack)
            {
                RadNumericTextBox2.Value = 10.5;
            }
        }
    }
}

1 Answer, 1 is accepted

Sort by
0
Vasil
Telerik team
answered on 14 Feb 2014, 09:47 AM
Hi Andrej,

I just tested your code and it works correct on my end. To identify why it is happening I would kindly ask you to provide us a bit more information:

What browser do you use?
What is the culture on your machine and in your server?
Is it happening in more than one browser?
Do you get some JS errors?
What .Net version are you using?

Regards,
Vasil
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 UI for ASP.NET AJAX, subscribe to the blog feed now.
Tags
Input
Asked by
Andrej
Top achievements
Rank 1
Answers by
Vasil
Telerik team
Share this question
or