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

Bug in RadDatePicker options..

15 Answers 240 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
Kræn Munck
Top achievements
Rank 1
Kræn Munck asked on 14 Mar 2011, 06:42 PM
Hi,

If i create a control like this:

RadDatePicker date = new RadDatePicker();
            date.EnableTyping = false;
            date.ShowPopupOnFocus = true;

Disabling typing also disables Popup.. ..but i only want the popup, that's why i disable typing! :D

So now i have a control that allows no input at all!

Disabling typing should actually force popup = true

Also, you should probably not show a caret in the input box when typing is disabled. Very misleading.

15 Answers, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 15 Mar 2011, 02:04 PM
Hello,


I tried same code and that got worked for me and the pop-up calendar is showing on clicking the image for the date-picker. I am using RadControls version 2010, 3, 1109, 35. If you want to show calendar popup when clicking the input, then you can make use of the client side api (by calling showPopup method).
RadDatePicker Client Object



-Shinu.
0
Kræn Munck
Top achievements
Rank 1
answered on 16 Mar 2011, 09:19 AM
Hi,

If you read my code you'd see there's a Property for this exact purpose.
0
Maria Ilieva
Telerik team
answered on 18 Mar 2011, 04:30 PM
Hi Kræn,

In your scenario I would suggest you to us the "ReadOnly" property of the controls instead of "EnableTyping". Give this a try and let me know how it goes.


All the best,
Maria Ilieva
the Telerik team
0
Andrew Putnam
Top achievements
Rank 1
answered on 06 Jul 2011, 11:15 PM
Using the "ReadOnly" property doesn't resolve the issue.  Any other suggestions, or is this a bug?  I'm having the same issue with the v.2011.1.519.40 build.
0
Maria Ilieva
Telerik team
answered on 12 Jul 2011, 10:05 AM
Hi Andrew,

Find attached a sample runnable application which shows the correct functionality of both methods for preventing typing in DateInput. Test it on your aide and let me know what the difference in your case is.

All the best,
Maria Ilieva
the Telerik team

Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

0
Maria Ilieva
Telerik team
answered on 12 Jul 2011, 10:05 AM
Hi Andrew,

Find attached a sample runnable application which shows the correct functionality of both methods for preventing typing in DateInput. Test it on your aide and let me know what the difference in your case is.

All the best,
Maria Ilieva
the Telerik team

Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

0
JR
Top achievements
Rank 1
answered on 26 Jul 2011, 09:32 AM
I have tried your example and it is still not working! Can you please provide a working example?
0
JR
Top achievements
Rank 1
answered on 28 Jul 2011, 01:00 PM
Hi Maria,
Do you have any solution to the particular problem, or shall I submit a support ticket for it?
0
Maria Ilieva
Telerik team
answered on 28 Jul 2011, 01:50 PM
Hi Jr,

Could you please let me know what exactly you mean by "still not working" ? Are you able to type in the input in the provided project. On my side the application works as expected. 
Please let me know what version of Telerik RadControls are you using?



Greetings,
Maria Ilieva
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

0
JR
Top achievements
Rank 1
answered on 28 Jul 2011, 03:12 PM
Hi Maria,
I am testing at your demo project that you have provided, so I guess the RadControls are the latest version.
So about the problem:
I am not able to type in the input, but the property "ShowPopupOnFocus" should open the calendar when I select the datainput.
If the property of the RadDatePicker "EnableTyping" is set to true, the other property "ShowPopupOnFocus" is working as expected. In the other case nothing happens. I need to ensure that the users cannot type in the dateInput field but when they click on it the calendar should pop up.


0
Maria Ilieva
Telerik team
answered on 03 Aug 2011, 10:56 AM
Hello Jr,

In this case possible approach is to cancel the keypressing in the keydown event of the DateInput component. Please find attached a sample application which presents this functionality. Test it locally and verify if it covers your requirements.

Greetings,
Maria Ilieva
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

0
BB
Top achievements
Rank 1
answered on 11 May 2012, 03:29 PM
Did this get solved? I'm having the same issue. My declaration is:

<telerik:RadDatePicker ID="ec_dtEndDate" runat="server" ShowPopupOnFocus="true" EnableTyping="False" />

I've also tried 

<telerik:RadDatePicker ID="ec_dtEndDate" runat="server" ShowPopupOnFocus="true" DateInput-ReadOnly="true" />

Either way, the date pop-up does not appear when the text box gets focus. Also the zip you supplied with the possible solution seems to be corrupted -can you repost?

I'm referencing the 2011.3.1305.40 build in my project in Visual Studio.

Thanks,
BB
0
Maria Ilieva
Telerik team
answered on 14 May 2012, 03:44 PM
Hi BB,

It seems that you have some problem downloading the project attached as on my end it appears to be correct. However here is the full code of the application:

JS:
<script type="text/javascript">
        function numericInput(e) {
            e = e || window.event;
            if (e.preventDefault) e.preventDefault();
            e.returnValue = false;
            return false;
        }
  
    </script>
ASPX:
<asp:Panel ID="Panel1" runat="server">
    <telerik:RadDatePicker ID="RadDatePicker1" ShowPopupOnFocus="true" runat="server">
        <DateInput runat="server">
        </DateInput>
    </telerik:RadDatePicker>
</asp:Panel>
C#:
protected void Page_Load(object sender, EventArgs e)
    {
       RadDatePicker1.DateInput.Attributes.Add("onkeydown", "numericInput(event);");
    }

I hope this works for you.

Regards,
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
BB
Top achievements
Rank 1
answered on 22 May 2012, 06:28 PM
Ok, but this didn't fix the problem. It prevents the user from typing in the text field but as stated here several times by me and others I need the date popup calendar to appear when the user clicks into the text field. Something like ;

DatePicker1.DateInput.Attributes.Add("onfocus", "showthecalendar(event);")


Is this possible?

BB
0
Maria Ilieva
Telerik team
answered on 28 May 2012, 08:02 AM
Hello BB,

Find attached the sample application you were previously unable to download.

I further tested it on my end and it seems to cover all your requirements. Test it on your end and let me know if this works for you.

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.
Tags
Calendar
Asked by
Kræn Munck
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Kræn Munck
Top achievements
Rank 1
Maria Ilieva
Telerik team
Andrew Putnam
Top achievements
Rank 1
JR
Top achievements
Rank 1
BB
Top achievements
Rank 1
Share this question
or