perspolis,
I wouldn't necessarily do that. What is the purpose here? Just killing
a database connection is a bad thing, since you could be closing it in the
middle of an important operation.
You can always just not place "pooling=true" in the connection string,
and the connections will not be pooled, they will close when your code
closes them.
Of course, you should always use the using statement to make sure your
connections close when you are done using them.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"perspolis" <re*****@hotmail.com> wrote in message
news:ei*************@TK2MSFTNGP15.phx.gbl...
Hi all
I use 'Pooling=true;' in my connection string;
how can I disable 'pooling' in my application and close all connections???
thanks in advance