As per our requirement highlighting the current date in radscheduler. For this we are assigning selecteddate property to current datetime, its working fine. But sometimes, its highlighting the next day.
We are always converting the usertime to EST and assigning it to SelectedDate property.
Please check the enclosed screenshot, when we run the sample code enclosed here, its displaying current date time as 10/22/2015 20:00:15 EST but in radscheduler its highlighting 10/23/2015.
This is observed when user time greater than 8PM EST.
Please download the sample code from below link:
Please let us know if there are any solution to fix this issue. Thank you.
7 Answers, 1 is accepted
If the Scheduler's TimeZoneID property is not set it will default to UTC 0, which could be the reason for the observed current date discrepancy. Please try setting it to your time zone and check whether the correct date is displayed. You can find the list of possible property values in this documentation article.
Thanks for the response.
It fixes the problem in some situations, but not all.
My application is in IST (Indian Standard Time) Server. We are using following code from the server to the User Timezone. Suppose user time zone is "Eastern Standard Time",
TimeZoneInfo oTZInfo = TimeZoneInfo.FindSystemTimeZoneById("Eastern Standard Time");
DateTime dtUserTime =TimeZoneInfo.ConvertTime(DateTime.Now, oTZInfo);
I have set the following properties for Rad Scheduler in PageLoad
radScheduler.TimeZoneID = "Eastern Standard Time";
radScheduler.SelectedDate = dtDateTime;
It is working in all the situations, but problem occures from IST 10:30 AM to 3:30 PM.
Please check the attached screenshot.
I was able to reproduce the issue with the provided controls (version 2014.1.225), fortunately running the sample project with the latest version of the controls displays the correct selected date so we suggest you update the controls.
On a side note, do have in mind that the public distribution of the official Telerik .dll files is strictly forbidden and may lead to legal actions against the offender. For this reason I deleted the link in your first post. In the future please, refrain from uploading the controls along with sample pages/projects and posting the links on the forums.
We upgrade Telerik.web.ui from 210.1.519.40 to 2015.3.930.40 for our product but since then in our project code below ,net System assembly method work only with case sensitive data where as it was behaving case-insensitve earlier which is expected one.i.e earlier if we pass "PACIFIC STANDARD TIME" it worrks fine but after upgrade it throws timezonenotfound error.
We are not aware of such behavior caused by the 2015.3.90.40 version of the controls. You can find attached a sample project and its code behind (the Page_Load handler) the TimeZoneInfo is correctly found using the string you posted ("PACIFIC STANDARD TIME"). Could you try running the sample project and let us know whether the "info" variable returns the expected value?
It seems the the .zip file did not attach properly for some reason. Let me try again.