"Peter Foti" <pe***@Idontwantnostinkingemailfromyou.com> wrote in
message news:10*************@corp.supernews.com...
"PiGei" <ja***************@hotmail.com> wrote in message
news:u9**************@TK2MSFTNGP11.phx.gbl... I read it, I did all the modification but the code isn't fired
anyway...
Apparently you didn't read it closely enough:
"Session_OnEnd does not support the request, response or server
objects"
You are attempting to use the server object, which is not supported.
And article 2491 does NOT use the server object. That is, it does
CreateObject instead of Server.CreateObject.
Hope this helps.
Regards,
Peter Foti
I reposted the code... but it still doesn't work.
The code under Application.UnLock seems not to be executed because the
field active in the DB doesn't change to 1
I'm desperated...
Sub Session_OnEnd
Application.Lock
Application("collegati") = Application("collegati") - 1
Application.UnLock
'================================================= ======================
=======
' inizio codice per settaggio flag active a 1 in uscita
'================================================= ======================
=======
Set dbConn = CreateObject("adoDB.connection")
dbConnstr = "Provider=Microsoft.Jet.OLEDB.4.0;Data
Source=c:\inetpub\wwwroot\my.mdb"
dbConn.Open dbConnstr
SQLstr = "UPDATE tbl_sessionid SET active='1' WHERE sessionid ='" &
Session("sID") & "'"
dbConn.Execute(SQLstr)
dbConn.Close
Set dbConn = Nothing
'================================================= ======================
=======
' fine codice per settaggio flag active a 1 in uscita
'================================================= ======================
=======
End Sub