ImageEn, unit ievision

IELibAvailable


Declaration

function IELibAvailable(ExeFolderOnly: Boolean = False) : Boolean;


Description

Returns true if the DLL's required by ImageEn are available (e.g. ielib64.dll for a 64bit ImageEn application). Also initializes the library.
If ExeFolderOnly is true, only the folder of the application EXE is checked for IELib DLLs.

Notes:
- You can use RegisterPlugIns as an alternative to IELibAvailable. See example below...
- The expected version of IELib is available from: ImageEnVersion.IELibVersionStr


Example

procedure TMainForm.FormShow(Sender: TObject);
begin
  if IELibAvailable() = False then
    MessageDlg(format('The installation is incomplete. Please reinstall %s', [Application_Name]), mtError, [mbOK], 0);
end;

// Which is the same as:
procedure TMainForm.FormShow(Sender: TObject);
begin
  IEGlobalSettings().RegisterPlugIns( [iepiIELib] );
  if not ( iepiIELib in IEGlobalSettings().ActivePlugIns ) then
    MessageDlg(format('The installation is incomplete. Please reinstall %s', [Application_Name]), mtError, [mbOK], 0);
end;


See Also

- RegisterPlugIns
- ImageEnVersion.IELibVersionStr
- DLLLoadingLog