|
|
|
|
|
- Specific properties
- Operating mode in the 64-bit applications
TwainProperty (Function) In french: TwainPropriété Allows you to get or change the properties of the current Twain device. This Twain device can be selected by TwainSelectSource. // Find out the scanner resolution nResolution is int = TwainProperty(TwainRésolution)
// Modify the resolution to 200 dpi bApply is boolean = TwainProperty(TwainRésolution, 200)
Syntax
Finding out the properties of the current Twain device Hide the details
<Result> = TwainProperty(<Property>)
<Result>: Integer - Value of the specified property.
- 0 if the TWAIN device does not support the modification of the requested property or the value of the requested property.
<Property>: Integer constant Property whose values are requested. This property corresponds to one of the following constants: | | TwainBitsByPixel | Number of bits per pixel. | TwainBrightness | Brightness of the device. <Value> must be included between -1000 and 1000. | TwainFeederEnabled | Management mode of feeder. <Result> is set to: - True if the feeder is enabled,
- False otherwise.
| TwainContrast | Contrast of the Twain device. <Result> will be included between -1000 and 1000. | TwainBorderDetectionEnabled | Detection mode of borders. <Result> is set to: - True if the detection of borders is enabled,
- False otherwise.
| TwainBarCodeDetectionEnabled | Detection mode of bar codes. <Result> is set to: - True if the detection of bar codes is enabled,
- False otherwise.
| TwainHeight | Maximum height (in millimeters). | TwainInterfaceControllable | Management mode of user interface. <Result> is set to: - True if the user interface can be disabled,
- False otherwise.
| TwainWidth | Maximum width (in millimeters) | TwainReady | Status of the device. <Result> is set to: - True if the device is plugged in and ready,
- False otherwise.
| TwainDuplex | Support for double side. <Result> is set to: - True if the device supports the double side,
- False otherwise.
| TwainDuplexEnabled | Management mode of double side. <Result> is set to: - True if the double side is enabled,
- False otherwise.
| TwainAutoResizeEnabled | Management mode of automatic resize. <Result> is set to: - True if the automatic resize of images is enabled,
- False otherwise.
| TwainAutoDeskewEnabled | Management mode of automatic image deskew. <Result> is set to: - True if the automatic deskew of images is enabled,
- False otherwise.
| TwainResolution | Resolution in pixels per inch. | TwainAutoRotationEnabled | Management mode of image rotation. <Result> is set to: - True if the automatic image rotation is enabled,
- False otherwise.
| TwainBlankPageSkipEnabled | Management mode of blank pages. <Result> is set to: - True if the blank pages are skipped,
- False otherwise.
| TwainType | Type of supported images. <Result> is set to: - TwainPalette: Manages the colored images issued from a palette (1, 4 or 8 bits per pixel).
- TwainRGB: Manages the RGB image (24 bits per pixel).
- TwainGrayScale: Manages the grayscale images.
- TwainBlackWhite: Manages the black and white images.
|
Modifying the properties of the current Twain device Hide the details
<Result> = TwainProperty(<Property> , <Value>)
<Result>: Boolean - True if the property was modified,
- False otherwise
<Property>: Integer constant Property whose value must be modified. This property corresponds to one of the following constants: | | TwainBitsByPixel | Number of bits per pixel. | TwainBrightness | Brightness of the device: <Value> will be included between -1000 and 1000. | TwainFeederEnabled | Management mode of feeder. <Value> is set to: - True if the feeder must be enabled,
- False otherwise.
| TwainContrast | Contrast of the Twain device. <Value> will be included between -1000 and 1000. | TwainBorderDetectionEnabled | Detection mode of borders. <Value> is set to: - True if the detection of borders must be enabled,
- False otherwise.
| TwainBarCodeDetectionEnabled | Detection mode of bar codes. <Result> is set to: - True if the detection of bar codes must be enabled,
- False otherwise.
| TwainDuplexEnabled | Management mode of double side. <Value> is set to: - True to enable the double side,
- False otherwise.
| TwainAutoResizeEnabled | Management mode of automatic resize. <Value> is set to: - True if the automatic resize of images must be enabled,
- False otherwise.
| TwainAutoDeskewEnabled | Management mode of automatic image deskew. <Value> is set to: - True if the automatic image deskew must be enabled,
- False otherwise.
| TwainResolution | Resolution in pixels per inch. | TwainAutoRotationEnabled | Management mode of image rotation. <Value> is set to: - True if the automatic image rotation must be enabled,
- False otherwise.
| TwainBlankPageSkipEnabled | Management mode of blank pages. <Value> is set to: - True if the blank pages must be skipped,
- False otherwise.
| TwainType | Type of supported images. <Value> corresponds to the following constant or combination of constants: - TwainPalette: Manages the colored images issued from a palette (1, 4 or 8 bits per pixel).
- TwainRGB: Manages the RGB image (24 bits per pixel).
- TwainGrayScale: Manages the grayscale images.
- TwainBlackWhite: Manages the black and white images.
|
<Value>: Integer New value for the requested property. Remarks Specific properties You have the ability to retrieve or modify the value of a property not listed in the above-mentioned Twain constants. In this case, the <Property> parameter will correspond to the value of the CAP_xxx or ICAP_xxx constant of TWAIN.H, associated with the requested property. Operating mode in the 64-bit applications In a 64-bit application, this function will automatically use the 64-bit Twain driver. The TWAIN cannot be used if this driver is not installed.
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|