MSWinsockLib, COM interface constants for VB.Net / VBScript

MSWinsockLib - interface constants

     This page contains simple VBA include for the MSWinsockLib COM library.

library parameters

File NameWINDOWS\system32\MSWINSCK.OCX
Guid{248DD890-BB45-11CF-9ABC-0080C7E7B78D}
Enums3

ProtocolConstants

enum, 2 members.
  'Protocol Constants
Public Enum ProtocolConstants

  'TCP protocol
  sckTCPProtocol = 0  '&H0

  'UDP protocol
  sckUDPProtocol = 1  '&H1
End Enum

StateConstants

enum, 10 members.
  'State Constants
Public Enum StateConstants

  'Socket is currently closed
  sckClosed = 0  '&H0

  'Socket is currently open
  sckOpen = 1  '&H1

  'Socket is listening for requests
  sckListening = 2  '&H2

  'Socket has a pending request
  sckConnectionPending = 3  '&H3

  'Socket is resolving remote computer name
  sckResolvingHost = 4  '&H4

  'Socket has resolved remote computer name
  sckHostResolved = 5  '&H5

  'Socket is connecting to remote computer
  sckConnecting = 6  '&H6

  'Socket has connected to remote computer
  sckConnected = 7  '&H7

  'Socket is closing connection to remote computer
  sckClosing = 8  '&H8

  'Socket has encountered an error
  sckError = 9  '&H9
End Enum

ErrorConstants

enum, 37 members.
  'Error Constants
Public Enum ErrorConstants

  'Invalid property value
  sckInvalidPropertyValue = 380  '&H17C

  'Property is write-only
  sckGetNotSupported = 394  '&H18A

  'Property is read-only
  sckSetNotSupported = 383  '&H17F

  'Out of memory
  sckOutOfMemory = 7  '&H7

  'Wrong protocol or connection state for the requested transaction or request
  sckBadState = 40006  '&H9C46

  'The argument passed to a function was not in the correct format or in the specified range
  sckInvalidArg = 40014  '&H9C4E

  'Successful
  sckSuccess = 40017  '&H9C51

  'Unsupported variant types
  sckUnsupported = 40018  '&H9C52

  'Invalid operation at current state
  sckInvalidOp = 40020  '&H9C54

  'Argument is out of range
  sckOutOfRange = 40021  '&H9C55

  'Wrong protocol for the requested transaction or request
  sckWrongProtocol = 40026  '&H9C5A

  'The operation is canceled
  sckOpCanceled = 10004  '&H2714

  'Invalid argument
  sckInvalidArgument = 10014  '&H271E

  'Socket is non-blocking and the specified operation will block
  sckWouldBlock = 10035  '&H2733

  'A blocking winsock operation is in progress
  sckInProgress = 10036  '&H2734

  'The operation is completed. No blocking operation is in progress.
  sckAlreadyComplete = 10037  '&H2735

  'The descriptor is not a socket
  sckNotSocket = 10038  '&H2736

  'The datagram is too large to fit into the buffer and is truncated
  sckMsgTooBig = 10040  '&H2738

  'The specified port is not supported
  sckPortNotSupported = 10043  '&H273B

  'Address in use
  sckAddressInUse = 10048  '&H2740

  'Address is not available from the local machine
  sckAddressNotAvailable = 10049  '&H2741

  'Network subsystem failed
  sckNetworkSubsystemFailed = 10050  '&H2742

  'The network cannot be reached from this host at this time
  sckNetworkUnreachable = 10051  '&H2743

  'Connection has timed out when SO_KEEPALIVE is set
  sckNetReset = 10052  '&H2744

  'Connection is aborted due to timeout or other failure
  sckConnectAborted = 10053  '&H2745

  'The connection is reset by remote side
  sckConnectionReset = 10054  '&H2746

  'No buffer space is available
  sckNoBufferSpace = 10055  '&H2747

  'Socket is already connected
  sckAlreadyConnected = 10056  '&H2748

  'Socket is not connected
  sckNotConnected = 10057  '&H2749

  'Socket has been shut down
  sckSocketShutdown = 10058  '&H274A

  'The attempt to connect timed out
  sckTimedout = 10060  '&H274C

  'Connection is forcefully rejected
  sckConnectionRefused = 10061  '&H274D

  'WinsockInit should be called first
  sckNotInitialized = 10093  '&H276D

  'Authoritative answer: Host not found
  sckHostNotFound = 11001  '&H2AF9

  'Non-Authoritative answer: Host not found
  sckHostNotFoundTryAgain = 11002  '&H2AFA

  'Non-recoverable errors
  sckNonRecoverableError = 11003  '&H2AFB

  'Valid name, no data record of requested type
  sckNoData = 11004  '&H2AFC
End Enum
WUtils.com