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

TwainCloseSourceManager(Int32) Method

In This Topic
Closes the Data Source Manager. If a source is open, disables and closes it as needed.
Syntax
'Declaration

 

Public Overloads Function TwainCloseSourceManager( _

   ByVal HANDLE As Integer _

) As Boolean
public bool TwainCloseSourceManager( 

   int HANDLE

)
public function TwainCloseSourceManager( 

    HANDLE: Integer

): Boolean; 
public function TwainCloseSourceManager( 

   HANDLE : int

) : boolean;
public: bool TwainCloseSourceManager( 

   int HANDLE

) 
public:

bool TwainCloseSourceManager( 

   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

True if success, else False -> Use TwainGetLastResultCode() and TwainGetLastConditionCode() methods for diagnosing the error. If the Source Manager is not open, does nothing and returns TRUE.
Remarks
If success, the twain state must be <= 2 (TWAIN_SM_LOADED). To get the TWAIN state, use the TwainGetState() method.
See Also