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

RadDatePicker selected Date issue

5 Answers 221 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
Apostol Apostolov
Top achievements
Rank 1
Apostol Apostolov asked on 19 Dec 2009, 01:17 PM
Hello Telerik,

I'm using a RadDatePicker inside a RadGrid in my project. My problem is that when I select a date the DateInput gets filled with the correct date, but when i access the property SelectedDate or DbSelectedDate of that DateInput(DatePicker), they're null. If I add another row (I get the current items(in a List) from which i bound the RadGrid, I add another one, add the list as a DataSource and call DataBind() again), the first DatePicker still has the issue described above, but the new one(on the new row) is fine, working perfectly right. The DatePicker is in a GridTemplateColumn of the RadGrid. Any help would be greatly appreciated. 

Also I have a DatePicker ouside of a RadGrid in the same project. I have the same issue with it, but with a slight difference. When it's first shown on the page it has the issue, but after one postback(asynchronous, I'm using AJAX, don't know if matters), everything's okay again, it works fine.

Thanks,
Apostol Apostolov

5 Answers, 1 is accepted

Sort by
0
Pavlina
Telerik team
answered on 19 Dec 2009, 04:21 PM
Hi Apostol,

I recommend you examine the following article, which elaborates on similar subject and let me know if it helps to achieve the desired functionality.
http://www.telerik.com/support/kb/aspnet-ajax/grid/using-raddatepicker-raddatetimepicker-as-editor-in-template-column-of-radgrid.aspx

I hope this helps.

Regards,
Pavlina
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Apostol Apostolov
Top achievements
Rank 1
answered on 22 Dec 2009, 09:15 AM
Hey,

Thank for the article, but I've achieved my desired functionality. Except it's not quite working. When I select a date from the calendar or type from the keyboard, everyting is ok - the date gets formatted and stuff. When I try to get the value typed in the datepicker - it's null.
After 1 postback if I type again the value  and try to access it - it's fine it's there. Any thoughts?
It's something with the datepicker, because just next to it there are rad numeric text box and rad text box and they're working just fine.

Thnaks again,
Apostol Apostolov
0
Apostol Apostolov
Top achievements
Rank 1
answered on 22 Dec 2009, 10:18 AM
Hey,

I've resolved the issue it was from my source code. Sorry for the wasted time :) 

Thanks anyway 
Apostol Apostolov 
0
Pavlina
Telerik team
answered on 23 Dec 2009, 01:21 PM
Hi Apostol,

I am happy to hear that you were able to find a solution for your case. Please do not hesitate to contact us if other questions or problems arise.

Greetings,
Pavlina
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0
Ron
Top achievements
Rank 1
Veteran
answered on 29 May 2011, 11:58 PM
EDIT: resolved my own question, which seemed to be related to my own code.
Tags
Calendar
Asked by
Apostol Apostolov
Top achievements
Rank 1
Answers by
Pavlina
Telerik team
Apostol Apostolov
Top achievements
Rank 1
Ron
Top achievements
Rank 1
Veteran
Share this question
or