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

How to show Date and Time popup together in RadDateTimePicker

1 Answer 189 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
Mahen
Top achievements
Rank 1
Mahen asked on 12 Jun 2013, 11:00 AM
Hi,

We have an application built in Silverlight, in it we are using RadDateTimePickerControl for Silverlight which shows Date and time together in the popup windows.

We also have few ASP.Net pages which we are showing in the above Silverlight application.

In ASP.net pages we are also using the RadDateTimePickercontral for ASP.net but in it Date and Time comes as separate selectable icons and user has to click date icon to select date and clock icon to select time.

We want both the control to behave same for consistency.
Could you suggest some approch or way to make the ASP.net RadDateTimePickerControl to behave same as Silverlight RadDataTimePickerControl.

Thanks and Regards,
Nitin Garg

1 Answer, 1 is accepted

Sort by
0
Kostadin
Telerik team
answered on 17 Jun 2013, 08:21 AM
Hi Mahen,

A possible solution is to hide the buttons and on input focus to open the date selection. After selecting a date you could show the time selection. Check out the following code snippet.
ASPX:
<telerik:RadDateTimePicker ID="RadDateTimePicker1" runat="server" ShowPopupOnFocus="true"
    DatePopupButton-Visible="false" TimePopupButton-Visible="false">
    <DateInput runat="server" OnClientDateChanged="DateChange"></DateInput>
</telerik:RadDateTimePicker>
JavaScript:
<script type="text/javascript">
    function DateChange(sender, args) {
        $find("<%= RadDateTimePicker1.ClientID %>").showTimePopup();
    }
</script>

I hope this helps.

Regards,
Kostadin
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.
Tags
Calendar
Asked by
Mahen
Top achievements
Rank 1
Answers by
Kostadin
Telerik team
Share this question
or