VistaDB 5
Example 






ClearAllPools Method
Empties all of the connection pools associated with the current connection.
Syntax
'Declaration
 
Public Shared Sub ClearAllPools() 
'Usage
 
VistaDBConnection.ClearAllPools()
public static void ClearAllPools()
public procedure ClearAllPools(); static; 
public static function ClearAllPools();
public: static void ClearAllPools(); 
public:
static void ClearAllPools(); 
Remarks
This operation will Dispose of each of the pooled objects. This function should be called when you want to ensure ALL connections are closed. A good example is when your app needs to switch to a maintenance mode and gain exclusive access to the database (to pack, repair, or back up a database). You would close any existing connections you have, call ClearAllPools(), and then reopen with no pooling and exclusive mode access.
Example
// Clear all pools must be done after you have
// closed any connections you have open or you are 
// just adding to the pool by closing the connection 
VistaDBConnection.ClearAllPools();
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also