OnImageAreaSelected

Description

This event is triggered when user selects an area (draws a rectangle) on an image in Dynamic Web TWAIN viewer.

Syntax

.RegisterEvent('OnImageAreaSelected',function(sImageIndex, left, top, right, bottom){...});

Parameters

<short> sImageIndex: specifies the index of image in buffer. The index is 0-based.
<int> left: specifies the x-coordinate of the upper-left corner of the rectangle.
<int> top: specifies the y-coordinate of the upper-left corner of the rectangle.
<int> right: specifies the x-coordinate of the lower-right corner of the rectangle.
<int> bottom: specifies the y-coordinate of the lower-right corner of the rectangle.

See Also

OnMouseRightClick
OnMouseMove
OnMouseDoubleClick
OnMouseClick
OnImageAreaDeSelected

Example

DWObject.RegisterEvent('OnImageAreaSelected', function(sImageIndex, left, top, right, bottom){
    alert(sImageIndex + 'left: ' + left);
});