[]
        
(Showing Draft Content)

GrapeCity.Documents.Drawing.Image.FromStream

FromStream Method

FromStream(Stream, bool, int)

Creates an Image from a stream. JPEG, PNG, WEBP, GIF, BMP and TIFF formats are supported.

Declaration
public static Image FromStream(Stream stream, bool ownStream = false, int frameIndex = 0)
Public Shared Function FromStream(stream As Stream, Optional ownStream As Boolean = False, Optional frameIndex As Integer = 0) As Image
Parameters
Type Name Description
Stream stream

The input stream.

bool ownStream

Indicates if the input stream should be closed when the Image is disposed.

int frameIndex

Index of an image frame to read, pass 0 for image formats not supporting multiple frames.

Returns
Type Description
Image

The newly created Image object.