Copies bytes from one stream to another using IStream::CopyTo.
_StreamCopyTo(ByRef $oSourceStream, ByRef $pDestStream, $iBytesToCopy, ByRef $iBytesRead, ByRef $iBytesWritten)
| $oSourceStream | Source IStream COM object. |
| $pDestStream | [in/out] Pointer to the destination IStream COM interface. |
| $iBytesToCopy | Number of bytes to copy. |
| $iBytesRead | [out] Number of bytes read from the source. |
| $iBytesWritten | [out] Number of bytes written to the destination. |
| Success: | 1 |
| Failure: | 0, sets @error to: 1 - Invalid source stream object. 2 - Invalid or failed to create destination stream. 3 - COM error (HRESULT in @extended). 4 - Failed to set destination stream size. 5 - Destination stream not open for writing. |