Microsoft SDK for Java

Write

This method of the ISequentialStream interface writes a specified number of bytes into the stream object starting at the current seek pointer.

Syntax

public int Write(byte buf[], int off, int len);



Return Values

S_OK -- The data was successfully written to the stream object.

E_PENDING -- Asynchronous storage only: Part or all of the data to be written is currently unavailable.

STG_E_MEDIUMFULL -- The write operation was not completed because there is no space left on the storage device.

STG_E_ACCESSDENIED -- The caller does not have sufficient permissions for writing to this stream object.

STG_E_CANTSAVE -- Data cannot be written for reasons other than no access or space.

STG_E_INVALIDPOINTER -- One of the pointer values is invalid.

STG_E_REVERTED -- The object has been invalidated by a revert operation above it in the transaction tree.

STG_E_WRITEFAULT -- The write operation was not completed due to a disk error. This value is also returned when attempting to write to a stream that was opened in simple mode (using the STGM_SIMPLE flag).

Parameters

buf The buffer to write from.
off The offset in the array to begin writing from.
len The number of bytes to write.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.