Topics
All
MacOS
(Only)
Windows
(Only)
Linux
(Only, Not)
iOS
(Only, Not)
Components
Crossplatform Mac & Win
Server
Client
Old
Deprecated
Guides
Examples
Videos
New in version:
9.5
10.0
10.1
10.2
10.3
10.4
10.5
11.0
11.1
11.2
Statistic
FMM
Blog
Queries an item property value.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
WIA | 6.5 | ❌ No | ✅ Yes | ❌ No | ❌ No | ❌ No |
Parameter | Description | Example |
---|---|---|
Item | The item of current device to query. For a scanner this is typical Flatbed or Feeder. see WIA.ListItems |
"Flatbed" |
Key | The property key. Can be a text with the name of the property or the corresponding ID. |
"Name" |
Returns value or error.
BMP | B96B3CAB-0728-11D3-9D7B0000F81EF32E |
JPEG | B96B3CAE-0728-11D3-9D7B0000F81EF32E |
PNG | B96B3CAF-0728-11D3-9D7B0000F81EF32E |
GIF | B96B3CB0-0728-11D3-9D7B0000F81EF32E |
TIFF | B96B3CB1-0728-11D3-9D7B0000F81EF32E |
Name | Value | Description |
FEEDER 1 | Scan by using the document feeder. | |
FLATBED 2 | Scan by using the flatbed. | |
DUPLEX 4 | Scan by using duplexer operations. | |
FRONT_FIRST 8 | Scan the front of the document first. This value is valid only when DUPLEX is set. | |
BACK_FIRST 16 | Scan the back of the document first. This value is valid only when DUPLEX is set. | |
FRONT_ONLY 32 | Scan the front only. | |
BACK_ONLY 64 | Scan the back only. This value is valid only when DUPLEX is set. | |
NEXT_PAGE 128 | Scan the next page of the document. | |
PREFEED 256 | Enable pre-feed mode. Position the next document while scanning. | |
AUTO_ADVANCE 512 | Enable automatic feeding of the next document after a scan. | |
ADVANCED_DUPLEX 1024 | Scan by using individual configuration settings for each child feeder item (WIA_CATEGORY_FEEDER_FRONT and WIA_CATEGORY_FEEDER_BACK). This flag cannot be set together with DUPLEX. A device that supports different scan settings for the front and back items should implement the optional ADF front and back items and it should support both DUPLEX and ADVANCED_DUPLEX. |
Queries resolution:
MBS( "WIA.ItemPropertyValue"; "Flatbed"; "Horizontal Resolution" )
Queries file extension:
MBS( "WIA.ItemPropertyValue"; "Flatbed"; "Filename extension" )
Queries media type:
MBS( "WIA.ItemPropertyValue"; "Flatbed"; "Media Type" )
Queries orientation:
MBS( "WIA.ItemPropertyValue"; "Flatbed"; "Orientation" )
// 0 = Portrait, 1 = Landscape, 2 = Rotate 180, 3 = Rotate 270
List properties of feeder:
Set Variable [ $item ; Value: "Feeder" ]
Set Variable [ $list ; Value: MBS("WIA.ItemPropertyKeys"; $item) ]
If [ MBS("IsError") ]
Show Custom Dialog [ "Error" ; $list ]
Else
Set Variable [ $count ; Value: ValueCount ( $list ) ]
If [ $count > 0 ]
Set Variable [ $i ; Value: 1 ]
Loop
Set Variable [ $key ; Value: GetValue ( $list; $i) ]
Set Variable [ $value ; Value: MBS("WIA.ItemPropertyValue"; $item; $key) ]
New Record/Request
Set Field [ WIA Scan::Device ; $item ]
Set Field [ WIA Scan::Key ; $key ]
Set Field [ WIA Scan::Value ; $value ]
Commit Records/Requests [ With dialog: Off ]
# Next
Set Variable [ $i ; Value: $i+1 ]
Exit Loop If [ $i > $count ]
End Loop
End If
End If
Query document handling select:
MBS( "WIA.ItemPropertyValue"; "feeder"; "Document Handling Select")
Created 28th November 2016, last changed 21st November 2019
WIA.ItemPropertyKeys - WIA.ListItems
Feedback: Report problem or ask question.