msToBlob method

Returns a blob object encoded as a Portable Network Graphics (PNG) format from a canvas image or drawing.

Syntax

var pngImageBlob = Canvas.msToBlob();

Parameters

This method has no parameters.

Return value

Type: Blob

The canvas element encoded in PNG format as a blob object.

Exceptions

ExceptionCondition
SecurityError
18

The image is not of the same origin or domain as the destination. Versions prior to a Windows Store app using JavaScript will return DOMException.SECURITY_ERR.

See also

Canvas

 

 

Show:
© 2014 Microsoft