473,770 Members | 1,973 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Losing session variable across response.redire ct in same folder

Hi, I have a routine that sets some session variables and then redirects the
user to another page in the same application/ same folder.

=======
Session("MyName ") = "Fredsmith"
Response.Redire ct("./AnewPage.aspx")
=======

If I go, Response.Write( Session("MyName ")) in the new page the session
variable does not exist.

I have all cookies enabled (session works for other pages) and understand
redirecting across different domains clears session variables etc but this
is a weird one!

I have debugged right up until the Response.Redire ct call and the session
variable exists, it's the Redirect that is killing the session variable.

Help appreciated
Cheers
Mark


Nov 18 '05 #1
1 3239
did you chack, that the application is not restarting at this point, for
some reason?
in AnewPage.aspx, do you still get session vars stored by other pages?

"John" <JD@noSpam.co m> wrote in message news:c5******** **@lust.ihug.co .nz...
Hi, I have a routine that sets some session variables and then redirects the user to another page in the same application/ same folder.

=======
Session("MyName ") = "Fredsmith"
Response.Redire ct("./AnewPage.aspx")
=======

If I go, Response.Write( Session("MyName ")) in the new page the session
variable does not exist.

I have all cookies enabled (session works for other pages) and understand
redirecting across different domains clears session variables etc but this
is a weird one!

I have debugged right up until the Response.Redire ct call and the session
variable exists, it's the Redirect that is killing the session variable.

Help appreciated
Cheers
Mark

Nov 18 '05 #2

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

Similar topics

1
1904
by: farooqazeem | last post by:
Hi guys, I’m facing some problem can u solve it. Problem is: I’m giving user Id and password in (Login_sess.asp) and submit it to page (sess_test.asp). I am setting session variable (session(“Sin”)=”Yes”) just before redirecting to the same page, but in first time I do not received the value of session variable when I redirect it, when I execute this process second time or redirect it only with the page name...
1
357
by: John | last post by:
Hi, I have a routine that sets some session variables and then redirects the user to another page in the same application/ same folder. ======= Session("MyName") = "Fredsmith" Response.Redirect("./AnewPage.aspx") ======= If I go, Response.Write(Session("MyName")) in the new page the session variable does not exist.
6
1526
by: Mike | last post by:
I have a function that is called when the user clicks the submit button, during this function i also set a varaible to "Y" due to that this function does a post back to the page then redirects. When I look for the session variable in the page.isPostBack section it equals nothing, it appears that the variable is not being passed to the post back section correctly. I have this due to I only want this function to run if the user has something...
2
291
by: Frank Bishop | last post by:
Can someone tell me why I'm losing my session variable when using Response.Redirect? When I use the RedirectFromLoginPage method(currently remmed out below), my session variable works fine, but I'm trying this other way with Response.Redirect and it seems all my redirection works, but it loses the session variable when I hit the redirected pages. Help appreciated. Here is code: <code> <%@ Import Namespace="System.Data.OleDB" %> <%@...
7
2246
by: Lucas Tam | last post by:
I'm calling the session object from an inherited page. The page is based off an herited class which outputs XML. Does anyone know why the session object would be nothing? httpcontext.current.request/response/etc all work, except for session. Thanks. --
9
2547
by: Adrian Parker | last post by:
We have a website that works everywhere but on a few PCs on this one site.. Asp.Net 1.1 Server = Windows 2003 Client = XP In the web.config we use - cookieless="false" in the browser settings they have "Always allow session cookies" set to true When the browser connects to the website the first page sets a session variable called "user_ref" to something and then calls another page. If on
0
983
by: Frank Bishop | last post by:
Can someone tell me why I'm losing my session variable when using Response.Redirect? When I use the RedirectFromLoginPage method(currently remmed out below), my session variable works fine, but I'm trying this other way with Response.Redirect and it seems all my redirection works, but it loses the session variable when I hit the redirected pages. Help appreciated. Thanks. Here is code: <code> <%@ Import Namespace="System.Data.OleDB" %>
0
1396
by: Jimmy Reds | last post by:
Hi, Sorry if this appears twice but I post through Google Groups and it had a funny 5 minutes and didn't appear to post this message the first time. I am setting session variables on a page then doing a header/location redirect to a second page however I am losing one of my session variables. Not all of them, just one.
4
2053
by: =?Utf-8?B?SlA=?= | last post by:
All the sudden my app has started to loose Session values after a Response.Redirect to another page in the same project. Ive read several post about setting the Terminate Boolean to false to solve this problem, but it hasnt work. On top of that it seems total random. I have a start.aspx page that all other web application call to begin the process. This start page creates needed Sessions and other miscellaneous tasks, and then redirects...
0
9617
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, well explore What is ONU, What Is Router, ONU & Routers main usage, and What is the difference between ONU and Router. Lets take a closer look ! Part I. Meaning of...
0
9453
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10099
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10036
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9904
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8929
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 projectplanning, coding, testing, and deploymentwithout human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5354
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 last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5481
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3607
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.