Check out example codes for "c# datetime format ymd". It will help you in understanding the concepts better.

Code Example 1

Use DateTime.Now.ToString("yyyy-MM-dd h:mm tt");

Learn ReactJs, React Native from akashmittal.com