Ok i have my chat server finally working, now i want to call a library by LoadLibrary and GetProcAddress, now i was wondering, how would i send data to the connected client from the dll? For winsock 1.01 compatiabilty.
Posted on 2002-02-19 12:35:24 by m00p
If you want you can insert some functions into your own dll and test all there. Standard way to load WinSocks is

invoke WSAStartup,101h,addr wsadata
invoke socket,PF_INET,SOCK_STREAM, 0
mov hSock,eax
invoke WSAAsyncSelect,hSock, hWnd, WM_SOCKET, FD_ACCEPT or FD_READ or FD_CLOSE
...

Exept this you can test every library for

invoke LoadLibrary, offset aLibName ;Load DLL
.if eax==NULL ;If there is no DLL
mov eax, 0

.else
mov ahLib, eax
invoke GetProcAddress, ahLib, offset aFuncName
.if eax!=NULL
mov funcAddr, eax
push parm1
push parm2
call
.else
...

Regards,
Mike
Posted on 2002-02-20 04:50:11 by Mike