|
|
|
|
|
ScanProperty (Function) In french: ScanPropriété Used to get and change the properties of a scanner. MonScanneur is Scanner
WIA_IPS_THRESHOLD is int = 6159
Seuil is int = ScanProperty(MonScanneur, WIA_IPS_THRESHOLD)
MonScanneur is Scanner
let CapacitéScanneur = ScanProperty(MonScanneur, scanPropertyCapability)
IF CapacitéScanneur & scanCapabilityFeeder THEN
Info("Le scanneur a un chargeur")
END
IF CapacitéScanneur & scanCapabilityFlatbed THEN
Info("Le scanneur a un plateau")
END
IF CapacitéScanneur & scanCapabilityDuplex THEN
Info("Le scanneur gère le recto-verso")
END
Syntax
Getting the properties of a scanner Hide the details
<Result> = ScanProperty(<Scanner> , <Property>)
<Result>: Type of the property Property value. If an error occurs, the ErrorOccurred variable is set to True and ErrorInfo returns the corresponding error message. <Scanner>: Scanner variable Name of the Scanner variable initialized with the information of the scanner for which we want to get a property. <Property>: Integer Property for which to get the values.
This property can correspond to: - one of the following constants from the WiaDef.h file in the Windows API: WIA_DIP_xxx, WIA_DPA_xxx, WIA_DPS_xxx, WIA_IPA_xxx, or WIA_IPS_xxx.
Please note: The properties managed depend on the driver used. The list of properties can be found at https://github.com/tpn/winddk-8.1/blob/master/Include/um/WiaDef.h. - one of the following constants:
| | scanPropertyCapability | Scanner capability. In this case, <Result> can be any combination of the following constants: - scanCapacityCharger Scanner has a feeder.
- scanCapacityPlaten The Scanner has a tray.
- scanCapacityRectoVerso Scanner supports duplex printing.
| scanPropertyPaperSize | Page size currently set for scanning. In this case, <Result> can be one of the following constants: | | - scanPaperSizeA0
- scanPaperSizeA1
- scanPaperSizeA10
- scanPaperSizeA2
- scanPaperSizeA3
- scanPaperSizeA4
- scanPaperSizeA5
- scanPaperSizeA6
- scanPaperSizeA7
- scanPaperSizeA8
- scanPaperSizeA9
- scanPaperSizeAuto
- scanPaperSizeB0
- scanPaperSizeB1
- scanPaperSizeB10
- scanPaperSizeB2
- scanPaperSizeB3
- scanPaperSizeB4
- scanPaperSizeB5
- scanPaperSizeB6
- scanPaperSizeB7
- scanPaperSizeB8
- scanPaperSizeB9
- scanPaperSizeC0
- scanPaperSizeC1
- scanPaperSizeC10
- scanPaperSizeC2
- scanPaperSizeC3
| - scanPaperSizeC4
- scanPaperSizeC5
- scanPaperSizeC6
- scanPaperSizeC7
- scanPaperSizeC8
- scanPaperSizeC9
- scanPaperSizeBusinessCard
- scanPaperSizeStatement
- scanPaperSizeDINB2
- scanPaperSizeDINB4
- scanPaperSizeLedger
- scanPaperSizeJISA2
- scanPaperSizeJISA4
- scanPaperSizeJISB0
- scanPaperSizeJISB1
- scanPaperSizeJISB10
- scanPaperSizeJISB2
- scanPaperSizeJISB3
- scanPaperSizeJISB4
- scanPaperSizeJISB5
- scanPaperSizeJISB6
- scanPaperSizeJISB7
- scanPaperSizeJISB8
- scanPaperSizeJISB9
- scanPaperSizeLegal
- scanPaperSizeLetter
- scanPaperSizeCustom
| Note: If the constant scanFormatPaperPerso is used, the dimensions must be specified in the property Zone property of the Scanner type variable. |
Changing the properties of a scanner Hide the details
<Result> = ScanProperty(<Scanner> , <Property> , <Value>)
<Result>: Boolean - True if the property was modified,
- False otherwise.
If an error occurs, the ErrorOccurred variable is set to True and ErrorInfo returns the corresponding error message.
<Scanner>: Scanner variable Name of the Scanner variable initialized with the information of the scanner for which we want to change a property. <Property>: Integer Property whose value is to be changed. This property can correspond to: - one of the following constants from the WiaDef.h file in the Windows API: WIA_DIP_xxx, WIA_DPA_xxx, WIA_DPS_xxx, WIA_IPA_xxx, or WIA_IPS_xxx.
Please note: The properties managed depend on the driver used. The list of properties can be found at https://github.com/tpn/winddk-8.1/blob/master/Include/um/WiaDef.h. - one of the following constants:
| | scanPropertyCapability | Scanner capability. In this case, <Result> can be any combination of the following constants: - scanCapacityCharger Scanner has a feeder.
- scanCapacityPlaten The Scanner has a tray.
- scanCapacityRectoVerso Scanner supports duplex printing.
| scanPropertyPaperSize | Page size currently set for scanning. In this case, <Result> can be one of the following constants: | | - scanPaperSizeA0
- scanPaperSizeA1
- scanPaperSizeA10
- scanPaperSizeA2
- scanPaperSizeA3
- scanPaperSizeA4
- scanPaperSizeA5
- scanPaperSizeA6
- scanPaperSizeA7
- scanPaperSizeA8
- scanPaperSizeA9
- scanPaperSizeAuto
- scanPaperSizeB0
- scanPaperSizeB1
- scanPaperSizeB10
- scanPaperSizeB2
- scanPaperSizeB3
- scanPaperSizeB4
- scanPaperSizeB5
- scanPaperSizeB6
- scanPaperSizeB7
- scanPaperSizeB8
- scanPaperSizeB9
- scanPaperSizeC0
- scanPaperSizeC1
- scanPaperSizeC10
- scanPaperSizeC2
- scanPaperSizeC3
| - scanPaperSizeC4
- scanPaperSizeC5
- scanPaperSizeC6
- scanPaperSizeC7
- scanPaperSizeC8
- scanPaperSizeC9
- scanPaperSizeBusinessCard
- scanPaperSizeStatement
- scanPaperSizeDINB2
- scanPaperSizeDINB4
- scanPaperSizeLedger
- scanPaperSizeJISA2
- scanPaperSizeJISA4
- scanPaperSizeJISB0
- scanPaperSizeJISB1
- scanPaperSizeJISB10
- scanPaperSizeJISB2
- scanPaperSizeJISB3
- scanPaperSizeJISB4
- scanPaperSizeJISB5
- scanPaperSizeJISB6
- scanPaperSizeJISB7
- scanPaperSizeJISB8
- scanPaperSizeJISB9
- scanPaperSizeLegal
- scanPaperSizeLetter
- scanPaperSizeCustom
| Note: If the constant scanFormatPaperPerso is used, the dimensions must be specified in the property Zone property of the Scanner type variable. |
<Value>: Type corresponding to the property New value for the property. Business / UI classification: UI Code
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|