comInputChars

C Scripting Language
Reference Manual
Version 4.4.0

<< Back  End  Next >>
 
 
INDEX
Introduction
Installation
Using the CSL executive
Language
Directives
System library
String library
Math library
Regular expression lib.
File library
Database library
Async Communication
   comBits
   comBps
   comClose
   comFlow
   comInputChars
   comOpen
   comParity
   comPurgeInput
   comRead
   comReadChar
   comReadTimeout
   comStops
   comWaitForOutput
   comWrite
Registry/Profile handling
Windows control
C API
C++ Class Interface
CSL links
  
comInputChars(
  const handle)     // async handle

Query # of characters in input queue. Note there may be in fact more characters waiting in the device input buffer than reported by comInputChars. Use this function only to find out if any character will be returned by the next read or not. Don't use this function to wait until a certain amount of characters are available, that may not work on all platforms.

Example:

var n = comInputChars(hdl);
if (n > 0)
   sysLog('Next read will return at least '|n|' chars');
else
   sysLog('Next read will wait');
  Copyright © IBK Landquart Last revision: 27.05.2002 << Back  Top  Next >>