AllAPI Network - The KPD-Team

 
Allapi Network
 API-Guide
 ApiViewer

 API List

 
API Resources
 Tips & Tricks
 VB Tutorials
 Error Lookup
 
Misc Stuff
 VB examples
 VB Tools
 VB Links
 Top Downloads
 
This Site
 Search Engine
 Contact Form
 

Donate to AllAPI.net

getsockopt

The Windows Sockets getsockopt function retrieves a socket option.

VB4-32,5,6
Declare Function getsockopt Lib "wsock32.dll" (ByVal s As Long, ByVal Level As Long, ByVal optname As Long, optval As Any, optlen As Long) As Long

VB.NET
System.Net.Sockets.Socket.SetSocketOption

Operating Systems Supported
Requires Windows Sockets 2.0

Library
Wsock32.dll

Parameter Information
· s
[in] A descriptor identifying a socket.

· level
[in] The level at which the option is defined; the supported levels include SOL_SOCKET and IPPROTO_TCP. See the Protocol-specific Annex (a separate document included with the Win32 SDK) for more information on protocol-specific levels.

· optname
[in] The socket option for which the value is to be retrieved.

· optval
[out] A pointer to the buffer in which the value for the requested option is to be returned.

· optlen
[in/out] A pointer to the size of the optval buffer.

Return Values
If no error occurs, getsockopt returns zero. Otherwise, a value of SOCKET_ERROR is returned, and a specific error code can be retrieved by calling WSAGetLastError.

Examples

Related Functions

No VB.NET Example Found

 

 


Copyright © 1998-2007, The Mentalis.org Team - Privacy statement
Did you find a bug on this page? Tell us!
This site is located at http://allapi.mentalis.org/