Re: ADO Connection object in Session_OnEnd

From: Aaron [SQL Server MVP] (ten.xoc_at_dnartreb.noraa)
Date: 09/24/04


Date: Fri, 24 Sep 2004 09:19:59 -0400

It might help if you tell us WHAT error.

-- 
http://www.aspfaq.com/
(Reverse address to reply.)
"Agoston Bejo" <gusz1@freemail.hu> wrote in message
news:OOX4xijoEHA.2764@TK2MSFTNGP11.phx.gbl...
> Hi!
> Why doesn't the following code work?
>
> Sub Session_OnEnd
>  Dim Conn
>  Set Conn = Server.CreateObject("ADODB.Connection")
>  Conn.ConnectionString = Application("Connection_String")
>  Conn.Open    'here is the error
> ...
> End Sub
>
>
> A Conn object is created the same way in Session_OnStart and is used
> throughout the application, and Application("Connection_String") still
> exists here (I tested).
> So I suppose the error is caused by the fact that we are in Session_OnEnd.
>
>


Relevant Pages

  • Re: ADO Connection object in Session_OnEnd
    ... (Reverse address to reply.) ... "Agoston Bejo" wrote in message ... > Sub Session_OnEnd ... > Set Conn = Server.CreateObject ...
    (microsoft.public.scripting.vbscript)
  • Re: ADO Connection object in Session_OnEnd
    ... (Reverse address to reply.) ... "Agoston Bejo" wrote in message ... > Sub Session_OnEnd ... > Set Conn = Server.CreateObject ...
    (microsoft.public.inetserver.asp.db)
  • Re: ADO Connection object in Session_OnEnd
    ... (Reverse address to reply.) ... "Agoston Bejo" wrote in message ... > Sub Session_OnEnd ... > Set Conn = Server.CreateObject ...
    (microsoft.public.inetserver.asp.general)
  • Re: ADO connection state and object destruction Problem/Question
    ... Public Function FindEmployees(ByVal Name As String, ... Dim strDesc As String ... Dim conn As ADODB.Connection ... Public Sub ClearErrorInfo(ByRef lngErr As Long, ByRef strDesc As String, _ ...
    (microsoft.public.data.ado)
  • Re: Using web service
    ... > from the Access database to keep the sample simple) ... > Private conn As New ... > End Sub ... >> You can just move it into the dataset of the acces file, ...
    (microsoft.public.dotnet.languages.vb)