Click here to Skip to main content
15,885,365 members
Articles / Desktop Programming / MFC

Server & Client IP Sockets

Rate me:
Please Sign up or sign in to vote.
3.30/5 (7 votes)
6 Apr 20052 min read 63.4K   8.2K   36  
Offers services by servers, use of services by clients, via IP sockets.
// SOCDLL.cpp : Defines the entry point for the DLL application.
//

#include "stdafx.h"
#include "SOCDLL.h"

BOOL APIENTRY DllMain( HANDLE hModule, 
                       DWORD  ul_reason_for_call, 
                       LPVOID lpReserved
					 )
{
    switch (ul_reason_for_call)
	{
		case DLL_PROCESS_ATTACH:
		case DLL_THREAD_ATTACH:
		case DLL_THREAD_DETACH:
		case DLL_PROCESS_DETACH:
			break;
    }
    return TRUE;
}

/* This is an example of an exported variable
SOCDLL_API  int nSOCDLL=0;

// This is an example of an exported function.
SOCDLL_API int fnSOCDLL(void)
{
	return 42;
}

// This is the constructor of a class that has been exported.
// see SOCDLL.h for the class definition
CSOCDLL::CSOCDLL()
{ 
	return; 
}*/
extern "C" SOCDLL_API int DllRegisterServer(void){return true;}
extern "C" SOCDLL_API int DllUnregisterServer(void){return true;}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Web Developer
United Kingdom United Kingdom
BSc (St.Andrews(1963-67))
MSCE
Systems Programmer 39+yrs
Married to first wife 35yrs & counting, four grown-up children
Religious opinions similar to MelG's
It is not the gnosis, but the praxis must be the fruit. (Aristotle)

Comments and Discussions