473,466 Members | 1,354 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

On Session_OnStart() getting fired when going from page to page at the same level as the global.asa

This is a standard ASP application that has several pages at the root
withthe global.asa. I set a session variable session("accountid") =
"123456" within an asp page and then response.redirect to the next page and
immediately response.write session("accountid") and I get back nothing.
But if I set a session variable session("accountid") = "123456" within an
asp page and response.redirect to a page in a sub directory and immediately
response.write session("accountid") I get back 123456 on the screen.
Please help.
Jul 19 '05 #1
3 2310
Steve,

Looks like the Session_OnStart is not firing, probably because the folder is
not set up as an application, etc.

--
Manohar Kamath
Editor, .netWire
www.dotnetwire.com
"Steve Mauldin" <st**********@hotmail.com> wrote in message
news:eu**************@tk2msftngp13.phx.gbl...
This is a standard ASP application that has several pages at the root
withthe global.asa. I set a session variable session("accountid") =
"123456" within an asp page and then response.redirect to the next page and immediately response.write session("accountid") and I get back nothing.
But if I set a session variable session("accountid") = "123456" within an
asp page and response.redirect to a page in a sub directory and immediately response.write session("accountid") I get back 123456 on the screen.
Please help.

Jul 19 '05 #2
Manohar,

The folder is setup as an application and I have tested the global.asa and
it is firing on eachpage load in the the root directory. I set in the
Session On Start in the global.asa a session variable session("accountid") =
"000000" then I call page1.asp in the root and issue session("accountid") =
"123456" and then response.write session("accountid") and I get 123456 on
the screen. I then response.redirect to page2.asp and response.write
session("accountid") and I get 000000 on the screen. The Global.asa
session on start is getting fired on every page load in the root. This is
the first time I have ever seen this happen and I have done several ASP
applications. Any Ideas would be helpful. And, If anyone is wondering,
cookies are turned on and if I use cookies to pass data from page to page it
works fine. I am trying to move to session variables so when I port to
ASP.NET I can use munging instead of cookies. Thanks for the help.

Steve Mauldin

"Manohar Kamath [MVP]" <mk*****@TAKETHISOUTkamath.com> wrote in message
news:OR*************@TK2MSFTNGP10.phx.gbl...
Steve,

Looks like the Session_OnStart is not firing, probably because the folder is not set up as an application, etc.

--
Manohar Kamath
Editor, .netWire
www.dotnetwire.com
"Steve Mauldin" <st**********@hotmail.com> wrote in message
news:eu**************@tk2msftngp13.phx.gbl...
This is a standard ASP application that has several pages at the root
withthe global.asa. I set a session variable session("accountid") =
"123456" within an asp page and then response.redirect to the next page

and
immediately response.write session("accountid") and I get back nothing. But if I set a session variable session("accountid") = "123456" within an asp page and response.redirect to a page in a sub directory and

immediately
response.write session("accountid") I get back 123456 on the screen.
Please help.


Jul 19 '05 #3
Thanks all for the help. I was able to figure this out. Session.abandon
does not actually execute until the page is completed and I had an
session.abandon in an included header page. so the session variable that was
set was getting
wiped at the end of the page, Doh!

"Steve Mauldin" <st**********@hotmail.com> wrote in message
news:eu**************@tk2msftngp13.phx.gbl...
This is a standard ASP application that has several pages at the root
withthe global.asa. I set a session variable session("accountid") =
"123456" within an asp page and then response.redirect to the next page and immediately response.write session("accountid") and I get back nothing.
But if I set a session variable session("accountid") = "123456" within an
asp page and response.redirect to a page in a sub directory and immediately response.write session("accountid") I get back 123456 on the screen.
Please help.

Jul 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: James | last post by:
Running on Xp with WSAD5.0.1 (acts the same in 5.1) an action class is simply not being called when it is configured identically with others called in the same manner. It never gets into the...
0
by: wannaknow | last post by:
When I set a cookie in global.asa in the sub session_onstart, even if I have "privacy" in IE 6.X set to "block all cookies" the cookie is still set, and I can get it on other pages. I can't find...
0
by: bb | last post by:
Hello In my Session_OnStart in Global.asa, I am setting some cookies. One of them, I set as follows: dim UserID UserID = Request.ServerVariables("LOGON_USER") Response.Cookies("User")("ID")...
31
by: Prabhat | last post by:
Hi All, The "Session_OnStart" event doesnot fire if the website has .htm file as the startup document. If I change the extension of the default document from ..htm to .asp then I can see the...
6
by: Binoy | last post by:
Hello, I am getting this error once in a while from my web sites. When I will refresh web browser, it goes off and sites are working fine. Directory structures and file names are as below- ...
7
by: sunil philip | last post by:
How do i identify the page that fired a method? e.g. page1.html ----------- <Head> <script> document.write(myfun()); </script>
20
by: weston | last post by:
I've got a piece of code where, for all the world, it looks like this fails in IE 6: hometab = document.getElementById('hometab'); but this succeeds: hometabemt =...
0
by: Artur | last post by:
After trying to solve this, I noticed another strange thing. When in secure connection Page_Load method of page is not invoked (Load event not fired). I looked where this method is assigned to this...
2
by: parkchan | last post by:
Hi all, I've got an weird problem with Application variables in Global.asax.vb. I have three Application variables set up in Session_OnStart event and I'm displaying the values of those...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.