各位i老师亲吻一下我的这个程序是那里有问题请各位老师指点出来?谢谢
#include<windows.h>int main(void)
{
void GetSysInfo()
char szComputerName[MAXBYTE]={0};
char szUserName[MAXBYTE]={0};
unsigned long nSize=MAXBYTE;
OSVERSIONINFO OsVer;
OsVer.dwOSVersionInfoSize=sizeof(OSVERSINIFO);
GetVersionEx(&OsVer);
if(OsVer.dwPlatformId==VER_PLATFORM_WIN32_NT)
{
if(OsVer.dwMajorVersion==5 && OsVer.dwMinorVersion ==1)
{
printf("windows XP %s \r \n",OsVer.szCSDVersion);
}
else if(OsVer.dwMajorVersion ==5 && OsVer.dwMinorVersion ==0)
{
printf("winodws 2k \r \n");
}
}
else
{
printf("Ohter System \r\n");
}
GetComputerName(szComputerName,&nSize);
printf("cOMPUTER NAME IS %s \r\n");
nSize=MAXBYTE;
GeTuserName(szUserName,&nSize);
printf("User Name is %s \r\n",szUserName);
}