> ## Documentation Index
> Fetch the complete documentation index at: https://docs.abbyy.com/llms.txt
> Use this file to discover all available pages before exploring further.

# SaveToStream Method of the VirtualFileSystemNode Object

This method saves the contents of a file to the stream supported by the [**IWriteStream**](https://docs.abbyy.com/flexi-capture/sdk/api-reference/iwritestream.md) object.

> [!NOTE]
>
> The method is available for a file only.

## Syntax

```vb Visual Basic .NET theme={null}
Sub SaveToMemory( Result As WriteStream)
```

```cpp C++ theme={null}
HRESULT SaveToMemory(
  IWriteStream*  Result
);
```

## Parameters

**Result**

\[in] The data written to the stream.

## Return values

This method has no specific return values. It returns the [standard return values of ABBYY FlexiCapture SDK functions](https://docs.abbyy.com/flexi-capture/sdk/api-reference/errorcodes.md).

## See also

## [VirtualFileSystemNode](https://docs.abbyy.com/flexi-capture/sdk/api-reference/virtualfilesystemnode.md)
