Load Example VB

In this example, when the Load event fires, properties that control image display are set.

Private Sub ImgEdit1_Load(ByVal Zoom As Double)
    'Here are some examples of default settings you might
    'want to specify prior to displaying an image.

    'Repaint any changes immediately (ex. zoom or resolution
    'changes, etc.)
    ImgEdit1.AutoRefresh = True
    
    'ScrollBars already default to true, but this is
    'modifiable if desired
    ImgEdit1.ScrollBars = True
    
    'Scale black and white images to grayscale.  Keep color image
    'displayed as color images.
    ImgEdit1.DisplayScaleAlgorithm = wiScaleOptimize
    
    'Allow user to scroll image using keyboard shortcuts
    ImgEdit1.ScrollShortcutsEnabled = True
    
    'Display all OCR zones
    ImgEdit1.OcrZoneVisibility = wiOcrShowAllZones  '3
End Sub