_hwrite

3.1

  long _hwrite(hf, hpvBuffer, cbBuffer)    
  HFILE hf; /* file handle */
  const void _huge* hpvBuffer; /* address of buffer for write data */
  long cbBuffer; /* size of data, */  

The _hwrite function writes data to the specified file. This function supports huge memory objects (that is, objects larger than 64K, allocated using the GlobalAlloc function).

Parameters

hf

Identifies the file to be written to.

hpvBuffer

Points to a buffer that contains the data to be written to the file.

cbBuffer

Specifies the number of bytes to be written to the file.

Return Value

The return value indicates the number of bytes written to the file, if the function is successful. Otherwise, the return value is –1L.

Comments

MS-DOS error values are not available when an application calls this function.

See Also

hmemcpy, _hread, _lwrite