CaptureAreaOptionDlg Example for Visual Basic

'set options
    LEADRasterScr1.CaptureAreaOptionDlg hWnd, 0
    'do a capture using these options
    LEADRasterScr1.CaptureArea LEADRasterScr1.CaptureAreaType

    'copy the captured image to a Main Control
    LEADRasterView1.Raster.Bitmap = LEADRasterScr1.Bitmap
    
    'display the capture result info
    Text1.Text = CStr(LEADRasterScr1.CaptureInfoTop)
    Text2.Text = CStr(LEADRasterScr1.CaptureInfoLeft)
    Text3.Text = CStr(LEADRasterScr1.CaptureInfoWidth)
    Text4.Text = CStr(LEADRasterScr1.CaptureInfoHeight)
    
    'reset area options
    LEADRasterScr1.ResetAreaOptions