ssCore.Win.saveImage

Save a rectangular area of the application window to disk as a bitmap or Jpeg image.


Availability:

First available in version 3.0 build 2039.


Input Parameters:

left - [Optional] - Left coordinate (in pixels) of area to be saved.

top - [Optional] - Top coordinate (in pixels) of area to be saved.

width - [Optional] - Width (in pixels) of area to be saved.

height - [Optional] - Height (in pixels) of area to be saved

clientOnly - [Optional] - If set to 'TRUE' only the client area of the window (excludes the title bar and borders) will be saved, otherwise the specified rectangular portion of the window will be saved. Valid values include: true and false.

format - [Optional] - The format to use for saving the window image. The default is JPEG. Valid values include: bitmap and jpeg.

quality - [Optional] - Jpeg quality setting from 1 to 100 where 1 is the worst quality (best compression) and 100 is best quality (worst compression). The default is 90.

path - Full path of the file where the image should be saved. If the directory portion of the path does not exist the file will not be created. This parameter supports monikers.


Output Parameters:

No output parameters.


Asynchronous Mode:

When this method is called asynchronously, a return object containing the output parameters is passed to the specified callback function.

ssCore.Win.saveImage( paramsObject [, callbackParamsObject] [, errorParamsObject] );


Synchronous Mode:

When this method is called synchronously, a return object containing the output parameters is returned to the caller immediately.

var returnObject = ssCore.Win.saveImage( paramsObject );


Notes:

None.


Examples:

ssCore.Win.saveImage({left:10, top:10, width:100, height:100, clientOnly:true, path:"startdir://snapshot.jpg"});