Can someone show me how to display the current time & date in a message box .. format in yyyymmddhhmmss?
sorry i am new to C#. pls help me out. thks
longwar
Printable View
Can someone show me how to display the current time & date in a message box .. format in yyyymmddhhmmss?
sorry i am new to C#. pls help me out. thks
longwar
Note that upper case "M" is used for month and lower case for minute. Also, upper case "H" indicates 24 hour time and lower case indicates 12 hour. You can include "tt" to show "AM" or "PM" with 12 hour time.Code:MessageBox.Show(DateTime.Now.ToString("yyyyMMddHHmmss"));
thks very much. jmcilhinney