KsGetCommState

The availability of this function depends on what the device supports.

Retrieves the current control settings for a specified communications device.

Syntax

BOOL KsGetCommState(
     HANDLE hFile,
     LPDCB lpDCB
);

Parameters

hFile: a handle to the communications device. The KsCreateComm function returns this handle.

lpDCB: a pointer to a DCB structure that receives the control settings information.

Return value

If the function succeeds, it returns TRUE, otherwise FALSE. To get extended error information, call GetLastError.

Example

N/A

Requirements

  RT Win32
Minimum supported version 4.0 4.0
Header kscom.h kscom.h
Library KsApi_Rtss.lib ksapi.h

See also

KsCreateComm

KsSetCommState