UncleCoder.com

UncleCoder.com

Free programming examples and instructions

Get Indian time in C# -Asp.net

Demo and Code for how to get Indian time in C# -Asp.net

by Athil


Posted on 27 Jul 2018 Category: Asp.net Views: 67

Edited on 12 Jul 2019


Here I am going to show how to get Indian/any other countries Date and time in C# with timezone difference.

DEMO

TextBox1.Text = DateTime.UtcNow.AddHours(5).AddMinutes(30).ToString();

Here I added 5 hours and 30 minutes to UTC time as we know that difference is 5 h and 30 m with Indian time and UTC time. 

Like that we can take all other countries time.

 



Leave a Comment:


Advertisement