1. 首页
  2. 数据库
  3. 其它
  4. 获取当前系统本地时间精确到毫秒的实例

获取当前系统本地时间精确到毫秒的实例

上传者: 2021-01-03 08:58:48上传 PDF文件 27.62KB 热度 14次
实例如下: #include #include char* cur_time_c(char strDateTime[32]) { struct timeb tp_cur; ftime(&tp_cur); struct tm btm; #ifdef WIN32 localtime_s(&btm, &tp_cur.time); #else localtime_r(&tp_cur.time, &btm); #endif sprintf(strDateTime, d-d-d d:d:d.d,
下载地址
用户评论