This example will get the computer name
#include <stdio.h>
#include <windows.h>
#include <conio.h>
void main(void)
{
char szBuffer[256];
DWORD dwNameSize=256;
//get the computer name
GetComputerName(szBuffer, &dwNameSize);
//print name
printf(“%s \n”,szBuffer);
getch();
}
No related posts.
Related posts brought to you by Yet Another Related Posts Plugin.


















