473,804 Members | 2,064 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

SessionId-Problem - New in VS2005 - Each browser child window is a new session

Hello,

the following sample application in ASp.net 2.0 / VS2005 (Webproject).

in an testPage.aspx

............... .

<P><A href="01Test01A .aspx">Link to 01Test01 A</A></P>
<P><A href="01Test01B .aspx">Link to 01Test01 B</A></P>
Now start the page.

Now DO NOT click on the link, but right click on the first link and select
'In new window'.
Now right click on the second link and select 'In new Window'.

Now you have 3 internet browser pages visible.

All three are the same application.
All three are from the same user (session).

but if you check the sessionId for the three pages all are different.
(each page shows in this sample the SessionId).

This is catastropical situation.

I think more than 30% of all internet surfers use the method to open window
of the application by using the right mouse key and
open windows in a new window.
But all session data are lost.

I hope there is any solution, because without a solution we can not use asp
for our applications,
because more than 30% of application-users would have failed data
situations.

Remark: We have made the same test with Asp 1.x /VS2003, here all works
fine.

Any help would be fine.
Thank you.
Rolf Welskes
Oct 8 '06 #1
3 1704
Hello Rolf,

As for the mutiple sessionId when open pages from the same browser window
problem, based on my experience, it is due to the ASP.NET sessionstate
manager's lazy-loading mechanism. Actually, it is not because you open the
link/page in a new brower windows, but due to you send a new request to the
ASP.NET server. For ASP.NET web application, as long as you haven't stored
any data in the certain user's sessionState, the ASP.NET runtime will not
allocate a fixed sessionID for the current user session. You can verify
this by refresh the browser window instead of click a link (or right click
to open a page in new browser window. You will find that the ASP.NET will
always return a new sessionID each time you refresh the page(send a new
reqeust).

You can also find the description on this in the following ASPNET
sessionstate FAQ:

#ASP.NET Session State FAQ
http://www.eggheadcafe.com/articles/20021016.asp

To prevent the ASP.NET runtime from generating random sessionID, you can
add a test data into the SessionState so that the ID will be fixed for
seqential requests from the same client. e.g.

Session["data"] = "placeholde r";

Hope this helps. Please feel free to let me know if there is any other
questions or anything else we can help.
Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead

=============== =============== =============== =====

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.

=============== =============== =============== =====

This posting is provided "AS IS" with no warranties, and confers no rights.



Oct 9 '06 #2
Hello,
thank you.
If i put something in the ViewState it works fine.

Thank you again.
Rolf Welskes
"Steven Cheng[MSFT]" <st*****@online .microsoft.coms chrieb im Newsbeitrag
news:sT******** ******@TK2MSFTN GXA01.phx.gbl.. .
Hello Rolf,

As for the mutiple sessionId when open pages from the same browser window
problem, based on my experience, it is due to the ASP.NET sessionstate
manager's lazy-loading mechanism. Actually, it is not because you open the
link/page in a new brower windows, but due to you send a new request to
the
ASP.NET server. For ASP.NET web application, as long as you haven't stored
any data in the certain user's sessionState, the ASP.NET runtime will not
allocate a fixed sessionID for the current user session. You can verify
this by refresh the browser window instead of click a link (or right click
to open a page in new browser window. You will find that the ASP.NET will
always return a new sessionID each time you refresh the page(send a new
reqeust).

You can also find the description on this in the following ASPNET
sessionstate FAQ:

#ASP.NET Session State FAQ
http://www.eggheadcafe.com/articles/20021016.asp

To prevent the ASP.NET runtime from generating random sessionID, you can
add a test data into the SessionState so that the ID will be fixed for
seqential requests from the same client. e.g.

Session["data"] = "placeholde r";

Hope this helps. Please feel free to let me know if there is any other
questions or anything else we can help.
Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead

=============== =============== =============== =====

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscripti...ult.aspx#notif
ications.

Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscripti...t/default.aspx.

=============== =============== =============== =====

This posting is provided "AS IS" with no warranties, and confers no
rights.



Oct 11 '06 #3
Thanks for the followup.

glad that you've also got it working. If there is anything else we can
help, please feel free to post here.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead
This posting is provided "AS IS" with no warranties, and confers no rights.

Oct 12 '06 #4

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

Similar topics

2
1710
by: Bill | last post by:
I'm wondering how unique the sessionid is in ASP. What is the math behind it's creation, and what are the probobolities of it being reproduced, i.e. 1/10000? or 1 in twenty million? Can someone give me some guidance on this? I'm trying to create some unique numbers for data assignement, and would like a way that does not replicate. Thanks, Bill
5
1924
by: Soha El-Saeed | last post by:
Dear All; I want to ask about how could I know if a specific sessionid still exists or not. If there is a method or anything that can tell me about the existence of a specific sessionid . Thank You Soha El-Saeed
1
1847
by: Thomas Henz | last post by:
Hi! I'm looking for a way to change the length of the generated SessionID from 24 to a higher number. Please help :) Thanks a lot, Tom
2
3215
by: XML newbie: Urgent pls help! | last post by:
If I get SessionID in 1 function how do I carry that SessionID(value of this SessionID) to another function or another form within the same project
1
2748
by: TheDude5B | last post by:
Hi, I was wondering if it is possible to manually renew the sessionID? I have had a look around and not found anything about renewing it automatically. I was wanting to do this just to cover my back when using the sessionID in a table and dont want it duplicated. so once the data is entered into the table, i want to be able to then renew the sessionID for the
11
4770
by: kurt sune | last post by:
Does anyone know how to retrieve the current sessionId in Global.asax.ApplicationError? /k
2
9852
by: KMG | last post by:
How do I get a sessionid? I have tried: Dim mySession as HTTPSessionState Dim sSessionID as String mySessionID = nothing sSessionID = nothing sSessionID = mySessionID.SessionID and I get the error "Object reference not set to an instance of an object." When I add the "new" -- Dim mySession as New HTTPSessionState -- I get the
3
2140
by: Jim | last post by:
Using either EW or VSE2008, I want to have a GridView that will: - Insert the logged in user's UserId from either the User table or the membership table when the user inserts a record. - When the user views the GridView, only their records are shown. I don't want to use a query string that uses the UserID for securtiy resons, so I'm thinking that I can use a SessionID that is tied to the UserId? Requests: 1. Insert a record that will...
0
997
by: news.rz.uni-karlsruhe.de | last post by:
Up to now I call webmethods from clientside with he "EnableSession = true" switch on. What I want to do is call the webmethod without "EnableSession = true" but instead deliver the SessionID from the client as a parameter e.g. mywebmethod(SessionID) and than find the data which belongs to the SessionID on my own on the server. How can I access the stored SessionID on the client?
0
9716
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, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9595
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
10354
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
10359
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
10101
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
9177
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, and deployment—without 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...
1
7643
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
2
3837
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3005
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.