Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
#include <windows.h>
int WINAPI WinMain ( HINSTANCE, HINSTANCE, LPSTR, int )
{
char ComputerName [MAX_COMPUTERNAME_LENGTH + 1];
DWORD cbComputerName = sizeof ( ComputerName );
if ( GetComputerName ( ComputerName, &cbComputerName ))
{ MessageBox ( NULL, ComputerName, "Name of this computer:",
MB_OK | MB_ICONINFORMATION ); } }
#include <iostream>
#include <winsock.h>
using namespace std;
int main(int argc, char *argv[])
{
WSADATA wsa_data;
/* Load Winsock 2.0 DLL */
if (WSAStartup(MAKEWORD(2, 0), &wsa_data) != 0)
{
cerr << "WSAStartup() failed" << endl;
return (1);
}
char myhostname[256] ;
int rc = gethostname(myhostname, sizeof myhostname);
cout << myhostname << endl ;
WSACleanup(); /* Cleanup Winsock */
system("PAUSE");
return EXIT_SUCCESS;
}