COM running twice
-
Hi All, I have a simple ASP page that connects to a COM Component to add some data to my Database, it works 100% apart from the fact that it runs it twice? Is this a known problem or could someone explain how I can stop this. Here is the code from my ASP Page
AppMonitor = Server.CreateObject("AppMonitor.LoginDetails").InitialLogin
(Application("cdscConnection"), gstrAccountName, Session.SessionID, stest)and the actual component
Public Function InitialLogin( _
ByVal ConnectionString As String, _
ByVal AccountName As String, _
ByVal SessionID As String, _
ByRef stest As Variant _
) As Long
Dim UserID As String
UserID = "sa"
Dim Password As String
Password = ""
Dim sql As String
sql = "EXEC cdsc_TBTrace 0, '" & Replace(AccountName, "'", "''") & "', " & SessionID
On Error GoTo ErrorHandler
Set cn = New ADODB.Connection
cn.Open (ConnectionString)
cn.Execute (sql)
stest = "Success"
cn.Close
ErrorHandler:
With Err
stest = Err.Description & "
" & Err.Number
End With
End FunctionThanks, Gavin