ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / WLanguage functions / Standard functions / Windows functions / Scanner functions
  • Properties specific to Scanner variables
  • WLanguage functions
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
Scanner (Variable type)
In french: Scan
The Scanner type is used to handle the information from a scanner. You can define and change the characteristics of the scanner using different WLanguage properties.
Note: For more details on the declaration of this type of variable and the use of WLanguage properties, see Declaring a variable.
Example
// Scan d'une image
MonScanneur is Scanner = ScanSelect()
IMG_Scan = ScanToImage(MonScanneur)
Properties

Properties specific to Scanner variables

The following properties can be used to handle the characteristics of a scanner:
Property nameType usedEffect
AreaRectangleArea to be scanned (in thousandths of a millimeter). By default, a rectangle with all zero coordinates and dimensions (0,0,0,0) is used to scan the entire page.
Note This zone is taken into account by the ScanProperty function if the constant scanFormatPaperPerso is used.
BitPerPixelInteger
  • Number of bits per pixel,
  • scanBitsPerPixelDefault constant (default value) if the value of the property should not be changed in the next scan. The property will use the previous value.
BrightnessInteger
  • Brightness, between -1000 and 1000,
  • scanBrightnessDefault constant (default value) if the value of the property should not be changed in the next scan. The property will use the previous value.
ColorFormatInteger constantImage color format:
  • scanFormatColorAuto Color format automatically detected by device (default).
  • scanFormatColorRGB RGB image (24 bits per pixel).
  • scanFormatColorGrayLevel: Grayscale image.
  • scanFormatColorBlackWhite: Black and white image.
ContrastInteger
  • Contrast, between -1000 and 1000,
  • scanContrastDefault constant (default value) if the value of the property should not be changed in the next scan. The property will use the previous value.
DuplexInteger constantDuplex mode options:
  • scanDuplexDefault constant (default value) if the value of the property should not be changed in the next scan. The property will use the previous value.
  • scanRectoVersoYes: the scan is a duplex scan.
  • scanRectoVersoNon: the scan is a single-sided scan only.
HeightInteger
  • Maximum height (in thousandths of a millimeter),
  • scanHeightDefault constant (default value).
This property is read-only.
NameCharacter string
  • Scanner name,
  • Empty string if the variable has not been initialized (default value).
This property is read-only.
ProcedureProgressProcedure
  • Name of the WLanguage procedure called when scanning a page,
  • Empty string to not use a procedure (default value).
This procedure has the following format:
<Procedure name>(<Page number>,
<Progress percentage>)
where:
  • <Numéro de page> Number of scanned page.
  • <Progress percentage>: Scan progress percentage of the page (between 0 and 100)
If the procedure returns False, the scan is interrupted.
ResolutionInteger
  • Image resolution in pixels per inch,
  • scanResolutionDefault constant (default value) if the value of the property should not be changed in the next scan. The property will use the previous value.
ScanFromInteger constantIndicates the source of the scan:
  • scanFromAuto scan from feeder if there is a feeder and pages in the feeder, otherwise scan from tray (default value).
  • scanFromFeeder: scan from feeder.
  • scanfromPlateau: scan is performed from the plateau.
WidthInteger
  • Maximum width (in thousandths of a millimeter),
  • scanWidthDefault constant (default value).
This property is read-only.
Remarks

WLanguage functions

The following WLanguage functions use the Scanner type:
ScanGetRetrieves the characteristics of a scanner in a variable of type Scanner.
ScanPropertyUsed to get and change the properties of a scanner.
ScanSelectOpens a standard dialog box with the available scanners.
ScanToImageRetrieves a document from a scanner in a variable of type Image.
ScanToPDFSaves a document from a scanner to a PDF file.
ScanWithUserInterfaceSaves a document from a scanner to one or more files, using the scanner's user interface.
Minimum version required
  • Version 27
Comments
Click [Add] to post a comment

Last update: 03/28/2025

Send a report | Local help