Converts the images of specified indices in the buffer to a base64 string.

Syntax, imageType);


<int[]> indices: specifies the indices of images to be converted. The index is 0-based. If you are converting to BMP/JPG/PNG, make sure you pass only one index. Multiple indices are valid only for TIFF/PDF.
<EnumImageType> imageType: specifies the format.

Image Type     Allowed Value
BMP     EnumImageType.BMP
JPEG     EnumImageType.JPEG
TIFF     EnumImageType.TIFF
PNG     EnumImageType.PNG
PDF     EnumImageType.PDF

Return value


The result string is the pure base64 string with no extra info. For example,
To use the string in most circumstances, you need to add extra info like


EnumImageType is under namespace io.

EnumImageType.JPEG doesn't support B/W images.


var imagedata;
var imageviewer = DCSObject.getImageViewer("ImageViewerContainer");  // Get a specified image viewer
imagedata =[0,2],;

See also


Is this page helpful?

Leave a Reply

Your email address will not be published.