CDateTimeCtrl
-
Hi Guys, I am using CDateTimeCtrl in my project.I dont know how to get Date, Month and Year Separatly. If you Know explain me with simple code Thanks in Advance
How about reading the documentation in MSDN and letting us know what you did not understand after seeing the member functions of this class to get the date, month and year separately? Read GetTime function and refer the SYSTEMTIME structure.
I am a HUMAN. I have that keyword (??? too much) in my name........ ;-)_AnsHUMAN_b>
-
Hi Guys, I am using CDateTimeCtrl in my project.I dont know how to get Date, Month and Year Separatly. If you Know explain me with simple code Thanks in Advance
-
Hi Guys, I am using CDateTimeCtrl in my project.I dont know how to get Date, Month and Year Separatly. If you Know explain me with simple code Thanks in Advance
Use the method "GetTime" and then Format the CTime-object. Example to get the month: CTime timeTime; theDateTimeCtrl.GetTime(timeTime); CString strMonth(timeTime.Format(_T("%m")); Now the Month is in the string. Look in the documentation of strftime to get the formatting codes.