Dynamic Web TWAIN: How to split an image into two separate parts

In some cases, you may want to split an image into two separate parts. You can refer to the steps below

  1. Cut the required part from the selected image using the method CutFrameToClipboard

    NOTE:
    If you want to manually select a rectangle area on the image to cut, you also need to use the event OnImageAreaSelected to get the coordinates.

  2. Insert the cut part of image to the end of pages in bufferusing the method LoadDibFromClipboard

    NOTE:
    if you need to insert the part of image before or after the current image in buffer, you can set IfAppendImage property to false before calling LoadDibFromClipboard.

  3. For the original image, you can repeat the above steps or you can crop the 2nd part of image and make it a new image. The method used is Crop.