I have created a class as below, it simple connects to the database, however, at first page load the SQL server tells me 10 users has accessed the database, at second load around 15 and so on. Until it finally shuts down the SQL server...
Public Class DBConnection
Private Shared con As DBConnection
Private Shared DBCon As ADODB.Connection
Private Sub New()
DBCon = New ADODB.Connection
Public Shared Function getInstance() As ADODB.Connection
If con Is Nothing Then con = New DBConnection
What have i done wrong because something must be clearly wrong...
The Page will also at some times take an enourmeous time to load
So my question is how should i connect to my database and should maintain the connection
Code is written in VB.net and compiled to an DLL run by sharepoint