- Home
- Forum
- ASP.NET Core - EJ 2
- Disable auto timezone convertation
Disable auto timezone convertation
Hello,
Example 2: If clinet selects today and 16:00 PM. As a result i get: 2021-01-31 14:00PM
<ejs-datetimepicker id="datepickerSlotStartUpdate" ejs-for="@Model.SlotStart" floatLabelType="Always" placeholder="@L["SlotStart"].Value"></ejs-datetimepicker>
How to disable that functionality? Iam updating grid values with dialog. We have clients from different time zones and we are managing it our way. From this control we are expecting to get exactly the same date were entered by client.
Example: in this scenario, if client select today (2021-02-01) (time by default is 12:00AM) after that strange convert, I get date: 2021-01-31 ( - 2hours offset,so its 2021-01-31 10:00PM)
Example: in this scenario, if client select today (2021-02-01) (time by default is 12:00AM) after that strange convert, I get date: 2021-01-31 ( - 2hours offset,so its 2021-01-31 10:00PM)
<div class="form-group col-md-3">
<ejs-datepicker id="datepickerDeliveryDate" ejs-for="@Model.DeliveryDate" floatLabelType="Always" placeholder="@L["DeliveryDate"].Value"></ejs-datepicker>
</div>
<ejs-datetimepicker id="datepickerSlotStartUpdate" ejs-for="@Model.SlotStart" floatLabelType="Always" placeholder="@L["SlotStart"].Value"></ejs-datetimepicker>
SIGN IN To post a reply.
3 Replies
1 reply marked as answer
VS
Vignesh Srinivasan
Syncfusion Team
February 2, 2021 06:15 AM UTC
Hi Mantas,
We would like to inform you that, the DateTime Picker component will be rendered based on the System timezone. if you run the application with DateTime Picker component in the client and server both in different time zone, the time zone offset of the server machine should be assigned to serverTimeZoneOffset property to avoid any timezone differences.
For example the serverTimeZoneOffset value for server in India will be “+5.5” and server in US will be “-4.0”.
You can directly provide the specified TimeZone UTC value to the property to get rid of the reported issue in your application.
Regards,
Vignesh Srinivasan.
Marked as answer
MP
Mantas Parfionovas
February 3, 2021 09:55 AM UTC
No, its not working like this. Iam running UI and BE on my local machine and if iam selecting for example: Today (2/3/2021 - 00:00am), iam getting (2/2/2021 - 10:00pm). It even not reacting to that offset setting. Iam trying to add 2 or -2, it working the same.
<ejs-datetimepicker id="datepickerSlotStartUpdate" ejs-for="@Model.SlotStart" serverTimezoneOffset="-2"

<ejs-datetimepicker id="datepickerSlotStartUpdate" ejs-for="@Model.SlotStart" serverTimezoneOffset="-2"
<ejs-datetimepicker id="datepickerSlotStartUpdate" ejs-for="@Model.SlotStart" serverTimezoneOffset="2"
VS
Vignesh Srinivasan
Syncfusion Team
February 10, 2021 11:08 AM UTC
Hi Mantas,
We have checked your reported query, we cannot be able to replicate the issue in our end. We have checked the following steps.
- We checked by changing the different time zone.
- We checked with the client time Zone as Canada and server time zone as south India and it worked fine.
- We checked by printing the changed values form the server.
If you are still facing the issue, kindly share the below details.
- Please share the server time zone of your application.
- Please share the host server of your application, IIS Express or Azure.
Please provide the above requested information, based on that we will check and provide you a better solution quickly.
Regards,
Vignesh Srinivasan.
SIGN IN To post a reply.
- 3 Replies
- 2 Participants
- Marked answer
-
MP Mantas Parfionovas
- Feb 1, 2021 11:39 AM UTC
- Feb 10, 2021 11:08 AM UTC