|
-
May 2nd, 2002, 12:29 PM
#1
Thread Starter
Fanatic Member
using global.asa file
i've used these files before but now i can't get it to work.
i have set the application settings in IIS, placed the ASA file in the same directory as my web site and restarted my machine but i can't access the variables from my file......
Code:
<SCRIPT LANGUAGE="VBScript" RUNAT="Server">
Sub Application_OnStart
' Set our user count to 0 when we start the server
Application("ActiveUsers") = 0
End Sub
Sub Session_OnStart
' Change Session Timeout to 20 minutes (if you need to)</FONT>
Session.Timeout = 20
' Set a Session Start Time</FONT>
' This is only important to assure we start a session</FONT>
Session("Start") = Now
' Increase the active visitors count when we start the session</FONT>
Application.Lock
Application("ActiveUsers") = Application("ActiveUsers") + 1
Application.UnLock
End Sub
Sub Session_OnEnd
' Decrease the active visitors count when the session ends.</FONT>
Application.Lock
Application("ActiveUsers") = Application("ActiveUsers") - 1
Application.UnLock
End Sub
</SCRIPT>
now, when i set the application settings in IIS i just left it as "default application".
do i need to change it to anything else?
i only have one application running on this machine right now so i thought Default would be fine.
Thanks!
-
May 3rd, 2002, 11:02 AM
#2
This needs to be running as its OWN application. That way it'll read its own global.asa file and no ther one from the root of the server. Change the config in IIS.
-
May 3rd, 2002, 11:37 AM
#3
Thread Starter
Fanatic Member
hmmm......
i only have one application running in IIS.
when right click and check the propertys, then go to Home Directory it show the Application Settings.
it has App. Name which I just changed to my applications name but it also says Starting Point and has my applications name there as well.
and it still does not work........
you said it needs to be it's own application but it is and it's the only app running on IIS.
aaarrrrrgggg........
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|