![]() | FlushWrite |
Flushes the contents of the I/O write buffer to the device.
virtual HRESULT FlushWrite(bool bSendEnd = true, long lTimeout = CUR_TIMEOUT) sealed override;
[in] If true, the END signal is asserted with the last byte of the transfer. If false, no END signal is asserted.
[in] I/O timeout value in milliseconds.
Returns S_OK if successful, otherwise a failure HRESULT.
The following example demonstrates use of the FlushWrite function.
// CoAcme4321.cpp HRESULT Acme4321::Configure() { HRESULT hr = S_OK; // Send an IEEE 488.2 END signal with the last byte in the buffer, use the existing timeout value hr = io.FlushWrite(); return hr; }