As per title, would be nice to have this information in the .log
Cheers ..
Put date/time in logfile header
Moderator: Matt
Put date/time in logfile header
- Attachments
-
- log.jpg
- (34.08 KiB) Downloaded 2678 times
Re: Put date/time in logfile header
date and time is on the file creation itself, unless you modify and save the file i guess.
Re: Put date/time in logfile header
True, but that can be changed/lost etc.
I look at this from Excel, and it would be nice to have it in there (included is already the image name, so date / time would be helpful)
I look at this from Excel, and it would be nice to have it in there (included is already the image name, so date / time would be helpful)
Re: Put date/time in logfile header
// Get date / time into log header for Torque
CTime currtime = CTime::GetCurrentTime();
CString timestring;
timestring.Format(_T(" %02d/%02d/%04d::%02d:%02d:%02d"),
currtime.GetMonth(),
currtime.GetDay(),
currtime.GetYear(),
currtime.GetHour(),
currtime.GetMinute(),
currtime.GetSecond());
CString dline = "DESC: " + GetDocument()->m_pAddress->ecu_adr_desc + " : " +
GetDocument()->m_pImageHdlr->imagemgr[curimg].description + timestring + _T("\r\n");
h_consult_log.Write(dline.GetBuffer(0), dline.GetLength());
DESC: HCR32 SKYLINE (RB20DET) : HCR32_RB20DET_04U11_AT_MECR109 03/22/2012::23:42:21
Re: Put date/time in logfile header
Actually why is the month first... rearranging
Re: Put date/time in logfile header
Good stuff!