ImageEn, unit imageenio

TImageEnIO.SelectAcquireSource

TImageEnIO.SelectAcquireSource


Declaration


function SelectAcquireSource(Apis: TIEAcquireApis = [ieaTwain, ieaWIA]) : boolean;


Description


Prompts the user with a dialog to select a Twain, WIA or DCIM device. Use Apis to specify which sources are available to the user.

Any combination of the following can be used:
Value Description
ieaTwain Acquire from Twain device
ieaWIA Acquire using WIA (scanners or camera)
ieaDCIM Read from any connected device containing a DCIM folder (e.g. camera card in a slot or a USB connected camera) using the WPD API


Note: If your location is only [ieTwain] or [ieWIA] then the default Twain/WIA selector is shown. Otherwise a custom device selector is used (Use MsgLanguage to control the language in the custom dialog).

Returns False if user press "Cancel" button.


Demo


  Demos\ImageAcquisition\AllAcquire\AllAcquire.dpr



Example


if ImageEnView1.IO.SelectAcquireSource([ieaTwain, ieaWIA]) then
begin
  ImageEnView1.IO.Acquire;
  ImageEnView1.IO.SaveToFile('D:\MyImage.jpg');
end;