This method retrieves the largest physical size that can be scanned with a given scan device.

[Visual Basic]
Public Function GetPhysicalSize() As System.Drawing.SizeF
Public Function GetPhysicalSize(ByVal dpiX As Integer, ByVal dpiY As Integer) As System.Drawing.SizeF
[C#]
public System.Drawing.SizeF GetPhysicalSize();
public System.Drawing.SizeF GetPhysicalSize(int dpiX, int dpiY);

Parameters

dpiX
     Horizontal Resolution (in dots per inch)
dpiY
     Vertical Resolution (in dots per inch)

Return Value

The largest physical size that can be scanned. (If unsuccessful, the SizeF structure's Height and Width properties will be 0)

Explanation

The GetPhysicalSize method retrieves the largest physical size that can be scanned with a given scan device. To retrieve the largest physical size the DataSourceName, Mode, and Unit properties must be set. If the DataSourceName property is blank then prior to executing this method, please execute the SelectDataSource method. (If the OpenDataSource method has been executed, the DataSourceName is disabled and the open scan device will be used.) Set the Mode property from 0 to 2 and set the Unit to values supported by the datasource (scan device). The Width and Height parameters of the SizeF structure will return values depending on the Mode and Unit properties. If Unit is set to Pixel and no parameter is passed then the current resolution (dpi) will be used. 

To execute the GetPhysicalSize method you must first execute the Initialize method. If the OpenDataSource method is executed prior to executing the GetPhysicalSize method then the open datasource cannot be used by another application until that datasource (scan device) is closed.

See Also

Scan Members | Newtone.ImageKit.Wpf.ImageKit

The ImageKit WPF is created by Newtone Corporation