Set

HRESULT Set(
ULONG ulSize, 
const BYTE *pBlob);
HRESULT Set(
const VARIANT& var);

Parameters

ulSize

Size of bookmark data in bytes. If ulSize is zero, then the bookmark is cleared and uninitialized.

pBlob

Pointer to bookmark data. Ignored if ulSize is zero.

var

Variant of type byte array.

Return Code

S_OK

Method succeeded.

E_OUTOFMEMORY

Returned if allocation failed.

E_UNEXPECTED

Returned if the array could not be locked if you use the Variant.

E_INVALIDARG

Returned if the Variant is not a byte array.

Comments

Sets new data for the bookmark. Clear is implicitly called prior to setting the new data to free any memory allocated for any current bookmark data. The new data is copied.