GdPicture.NET.14
GdPicture14 Namespace / GdPictureImaging Class / TwainAcquireToGdPictureImage Method / TwainAcquireToGdPictureImage(Int32) Method
A Window Handle IE: Me.Handle. In most applications you can use nothing but on Citrix and WTS, this must be a top-level window or a child of a top level window.





In This Topic
TwainAcquireToGdPictureImage(Int32) Method
In This Topic
Acquires a single image, from the currently selected Data Source.
Syntax
'Declaration
 
Public Overloads Function TwainAcquireToGdPictureImage( _
   ByVal HANDLE As Integer _
) As Integer
public int TwainAcquireToGdPictureImage( 
   int HANDLE
)
public function TwainAcquireToGdPictureImage( 
    HANDLE: Integer
): Integer; 
public function TwainAcquireToGdPictureImage( 
   HANDLE : int
) : int;
public: int TwainAcquireToGdPictureImage( 
   int HANDLE
) 
public:
int TwainAcquireToGdPictureImage( 
   int HANDLE
) 

Parameters

HANDLE
A Window Handle IE: Me.Handle. In most applications you can use nothing but on Citrix and WTS, this must be a top-level window or a child of a top level window.

Return Value

0: The image could not created. Use the GetStat(), TwainGetLastResultCode() and TwainGetLastConditionCode() methods for diagnosing the error. Non-zero: GdPicture image identifier. The created image. The ReleaseGdPictureImage() method must be subsequently used to release the image from the memory.
Remarks
If success, set the created GdPicture image as a GdPicture image. By default, the default data source (DS) is opened, displays its dialog, and determines all the parameters of the acquisition and transfer. If you want to (try to) hide the DS dialog, see TwainSetHideUI. Before using this method check that the TWAIN state is >= 4 (TWAIN_SOURCE_OPEN) To get the TWAIN state, use the TwainGetState() method. To set the TWAIN state to 4, use the TwainOpenDefaultSource() or TwainOpenSource() method.

This method requires the Document Capture (TWAIN / WIA) component to run.

See Also