G
Guest
I have a single Windows form, in which I am using a connection object. I need the connection in many places in the form to execute commands. I need to know which of these is a better option and why
1. open and close the connection whenever i execute a command
2. pen the connection in the beginning, keep the connection open till i complete all my activites, close it at the end.
1. open and close the connection whenever i execute a command
2. pen the connection in the beginning, keep the connection open till i complete all my activites, close it at the end.