0

I would like to call a function from another file in the Session_OnStart part if global.asa, so I could declare some Session("variables") according to some data.

Is it possible?
How?

Edit: I found a workaround, where I have a global functions file that I include everywhere. So I added to the code to this file. It's not perfect, because even though it's a small piece of code, it still runs every refresh, instead of once at the Session_OnStart.

Any other solutions?

Tomer Amir
  • 1,515
  • 4
  • 27
  • 54

1 Answers1

0

It's indeed not possible to add include files to you global.asa. You could do the following:

Create a 'flag' in the session that says if it's a new session. Fill it in the Session_OnStart (i.e. Session("NewSession") = True) and verify this before executing your global function(s).

kloarubeek
  • 2,706
  • 20
  • 24