PrepareBitmap Method of the Engine Object

This method creates a copy of the specified bitmap image (HBITMAP) in FineReader Engine internal image format.

The output image obtained from this method may then be opened using the IEngine::LoadImageDoc method.



HRESULT PrepareBitmap(
  __int64            BitmapHandle,
  BSTR               DestinationFolderName,
  int                XResolution,
  int                YResolution,
  IPrepareImageMode* PrepareMode


void PrepareBitmap(
  Int64            BitmapHandle,
  string           DestinationFolderName,
  int              XResolution,
  int              YResolution,
  IPrepareImageMode PrepareMode

Visual Basic .NET

Sub PrepareBitmap( _
  BitmapHandle As Int64, _
  DestinationFolderName As String, _
  XResolution As Integer, _
  YResolution As Integer, _
  [PrepareMode As IPrepareImageMode = Nothing] _


[in] Specifies the handle of the GDI object (HBITMAP). This handle should be available to the process that operates ABBYY FineReader Engine. The handle is passed as __int64.
[in] Specifies the full path to the folder, where the image in internal format should be saved. This folder must exist; otherwise, an error code is returned.
[in] Specifies the horizontal resolution of the bitmap.
[in] Specifies the vertical resolution of the bitmap.
[in] Refers to the PrepareImageMode object that stores parameters for bitmap conversion in internal format. This parameter may be 0 in which case default parameters of the image preparation mode are used, or, if a profile has been loaded, the parameters set by this profile are used.

Return values

This method has no specific return values. It returns the standard return values of ABBYY FineReader Engine functions.


  • If you need to delete the files with prepared images when they are no longer necessary, implement the procedure in your application. These files will not be automatically removed from the disk by ABBYY FineReader Engine.
  • This method does not work if the Engine object is created using the OutprocLoader object.

See also




Working with Profiles

24.03.2023 8:51:52

Usage of Cookies. In order to optimize the website functionality and improve your online experience ABBYY uses cookies. You agree to the usage of cookies when you continue using this site. Further details can be found in our Privacy Notice.