该如何使用GetSystemTime()??
我在VC下建了一个win32 console工程,和一个c++文件
内容如下:
#include<stdlib.h>
#include<string.h>
#include<winbase.h>
#include<stdio.h>
void main()
{
LPSYSTEMTIME lpSystemTime;// address of system time structure
GetSystemTime(lpSystemTime);
printf("%s\n",lpSystemTime);
}
按照MSDN里说的加入了winbase.h文件。但是编译出现以下很多错误:
:\program files\microsoft visual studio\vc98\include\winbase.h(216) : error C2146: syntax error : missing ';' before identifier 'Internal'
d:\program files\microsoft visual studio\vc98\include\winbase.h(216) : error C2501: 'DWORD' : missing storage-class or type specifiers
d:\program files\microsoft visual studio\vc98\include\winbase.h(216) : error C2501: 'Internal' : missing storage-class or type specifiers
。。。。。。
winbase.h文件怎么会出错?
是不是哪里没有设置好呢?还是在这种工程环境下不能调用这个函数呢?