IXpsOMStoryFragmentsResource::GetStream method (xpsobjectmodel.h)

Gets a new, read-only copy of the stream that is associated with this resource.

Syntax

HRESULT GetStream(
  [out, retval] IStream **stream
);

Parameters

[out, retval] stream

A new, read-only copy of the stream that is associated with this resource.

Return value

If the method succeeds, it returns S_OK; otherwise, it returns an HRESULT error code. For information about XPS document API return values, see XPS Document Errors.

This method calls the Packaging API. For information about the Packaging API return values, see Packaging Errors.

Remarks

Reading from the IStream object returned by this method might return an E_PENDING error, which indicates that the stream length has not been determined yet. This behavior is different from that of a standard IStream object.

For more information about the content of StoryFragments part, see the XML Paper Specification.

This method calls the stream's Clone method to create the stream returned in stream. As a result, the performance of this method will depend on that of the stream's Clone method.

Requirements

Requirement Value
Minimum supported client Windows 7, Windows Vista with SP2 and Platform Update for Windows Vista [desktop apps | UWP apps]
Minimum supported server Windows Server 2008 R2, Windows Server 2008 with SP2 and Platform Update for Windows Server 2008 [desktop apps | UWP apps]
Target Platform Windows
Header xpsobjectmodel.h

See also

IXpsOMStoryFragmentsResource

Packaging Errors

XML Paper Specification

XPS Document Errors