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

RadTextBox gives empty value

12 Answers 452 Views
Input
This is a migrated thread and some comments may be shown as answers.
peter
Top achievements
Rank 1
peter asked on 06 Sep 2012, 10:12 AM
Hello! 

I'm currently using Radcontrols with version 2012.2.724.40

I have a login page, and when the page is loaded, the radtextbox used for the login input becomes automaticly filled with text by the browser memory with the last login used. When i do a postback the radtextbox returns empty string on the server side. Also in the server side when using requiredfiledvalidator it fires the error message indicating the field is empty.

Another way to test this problem is to fill any radtextbox in the form, then redirecto to another page, and then with the browser return button go back to the same page, see the previous filled text in the radtexbox's and confirm that they keep returning empty values both on client side or server side.

This problem only occurs in this current version. With 2012 Q1 or older releases it works fine.

12 Answers, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 11 Sep 2012, 12:23 PM
Hi Pedro,

We are aware of the described issue and it is already logged in our tracking system. Our dev team is actively working on its resolution and a fix should be available in the next official release which is planned for the end of October.

All the best,
Maria Ilieva
the Telerik team
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 their blog feed now.
0
Bill
Top achievements
Rank 1
answered on 26 Oct 2012, 02:29 PM
Any word on this fix? It's still broken in the latest release. RadDatePicker is also broken in a similar way.
0
Neil
Top achievements
Rank 1
answered on 26 Oct 2012, 03:09 PM
I'm curious, too. It's causing us a lot of problems.
0
Maria Ilieva
Telerik team
answered on 29 Oct 2012, 11:55 AM
Hi,

Thank you for contacting us.

Please note that our dev team is still in researching process for the mentioned problematic behaviour. It appears that this fix is more complicated than expected and could cause some braking changes in the control's behaviour. Therefore our developers are still discussing if the fix will be possible and if yes what would be the best way for its implementation with minor breaking changes for the input.

We will let you know what the stage of this task is as soon as our dev team come to a final conclusion for this item.

Thank you for your patience and excuse us for any inconvenience this problem may lead.

All the best,
Maria Ilieva
the Telerik team
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 their blog feed now.
0
Jason
Top achievements
Rank 2
answered on 18 Sep 2013, 01:09 PM
As of the 2013 Q2 release I'm still seeing this as a problem.  I have to physically tab/click into the username and password radtextboxes even if there are values present from browser stored credentials in order for the controls to recognize it has values in them.
0
Maria Ilieva
Telerik team
answered on 23 Sep 2013, 01:51 PM
Hello Jason,

I'm not completely sure if the issue you are facing is the one discussed in this forum thread. Could I kindly ask you to open a separate support ticket with detailed information for the problematic behavior. Thus we will be able to further investigate and provide straight to the point answer.

Regards,
Maria Ilieva
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
Philip Rendall
Top achievements
Rank 1
answered on 13 Dec 2013, 05:57 PM
Have you guys found a fix to this?  This is a huge problem.  I'm using RadControls for ASP.NET AJAX Q3 2013.
0
Maria Ilieva
Telerik team
answered on 18 Dec 2013, 12:46 PM
Hi Philip,

Could you please let  me know if the mentioned behaviour appear in the RadTextBox control or in the RadNumericTextBox or RadDateInput control? Note that we fully support the auto complete feature for the RadTextBox and this should properly work in Q3 2013 version of he controls. This behavior is slightly different for the other two input component as in case RadNumericTextBox is used this is working properly in case the culture of the server and on the client is the same. For the RadDateInput component the visible part of the input should contains the whole date and the auto complete feature is again working as expected.


Regards,
Maria Ilieva
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
Desarrollo
Top achievements
Rank 1
answered on 05 Feb 2014, 03:00 PM
I have the same problem that peter has, in the login page.
I'm using UI for asp.net ajax v.2013.3.1324.40.
When the submit button is clicked the "text" property of the radtextbox (user and password) returns empty string and the requiredfieldvalidator didn't recognize the error, 'casue the radtextbox has values but in the server side I got empty string.

I don't know if you already solve this issue, because I want to know how to resolve it.

Thx for your comments
0
Philip Rendall
Top achievements
Rank 1
answered on 05 Feb 2014, 03:11 PM
Sorry Maria,

I did not receive a notice that you updated this post.  I am using RadTextBox.

Philip
0
Maria Ilieva
Telerik team
answered on 10 Feb 2014, 12:04 PM
Hi Philip,

As there should be no similar issues in the RadTextBox from Q3 2013 release it would be best if you could open a separate support ticket and send us sample runnable application which demonstrates the excat problem, Thus we will be able to debug it locally and advise you further.


Regards,
Maria Ilieva
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.
0
Emre
Top achievements
Rank 1
answered on 15 Jul 2014, 11:04 AM
A workaround for this issue is to use hiddenfields. Although the values of Username and Password RadTextBoxes are not passed to server they can be grabbed by JavaScript. With JS, the username and password can be set as a hiddenfield's value and their value will be passed during postback. Do this during OnClientClicked event of Button.

Client Side:

<script>
    function setHiddenFields() {
        var userNameTxt = $find("<%= UserName.ClientID %>");
        var passwordTxt = $find("<%= txtPassword.ClientID %>");
        var name = userNameTxt._textBoxElement.value
        var pass = passwordTxt._textBoxElement.value
        $("#<%=hdnUserName.ClientID %>").val(name);
        $("#<%=hdnPassword.ClientID %>").val(pass);
    }
</script>

<div id="loginDiv>
<telerik:RadTextBox ID="UserName" runat="server"></telerik:RadTextBox>
 <telerik:RadTextBox ID="Password" runat="server" TextMode="Password"></telerik:RadTextBox>
<telerik:RadButton ID="LoginButton" runat="server" Text="Giriş" OnClientClicked="setHiddenFields"
            OnClick="LoginButton_Click"> </telerik:RadButton>

<asp:HiddenField ID="hdnUserName" runat="server" />       
<asp:HiddenField ID="hdnPassword" runat="server" />
</div>



Server side:

     protected void btnGiris_Click(object sender, EventArgs e)
        {
            string username= UserName.Text;

            string pass = Password.Text;


            if (string.IsNullOrEmpty(username))
                username = hdnUserName.Value;

            if (string.IsNullOrEmpty(pass))
                pass = hdnPassword.Value;

.
.
.
}
Tags
Input
Asked by
peter
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Bill
Top achievements
Rank 1
Neil
Top achievements
Rank 1
Jason
Top achievements
Rank 2
Philip Rendall
Top achievements
Rank 1
Desarrollo
Top achievements
Rank 1
Emre
Top achievements
Rank 1
Share this question
or