I would like to output an error report for my code with a filename formatted as "ErrorReport_date_time.rpt". as of right now i can output a file as "ErrorReport.rpt" or with no extension but when adding the date and time, it does not create a file.
void ErrorHandler::Open(char const filename)
string fileType = ".rpt";
time_t t = time(0);
struct tm * now = localtime(&t);
ss << filename
<< (now->tm_year + 1900) << '-'
<< (now->tm_mon + 1) << '-'
<< (now->tm_mday) << '_'
<< (now->tm_hour) << ':'
<< (now->tm_min) << ':'