PROBLEM: Ported working vs2003 Asp.net project to VS2005. Response.Redirect terminates the session.
Environment: W2000 Advanced Server, IIS, vb.net
Both vs 2003 and vs2005 on same machine.
Changed the dll name to appname05.dll so that it would register
The appname is the same for vs2005
but the location and sitename in the iis was changed.
I tried the following prior to ‘response.redirect’
Response.AddHeader("P3P",
"CP=""CAO PSA OUR""")I tried entering the server path in the browser.Both to no avail.I
tried some mods to the web.config such as the machine settingRequest anyone experienced with
this problem to please respond.
visual studio 2005ASP.NETasp.NET 2.0web site project
Maybe if you use Server.Transfer instead of Response.Redirect?
To my knowledge, the conversion wizard between 2003 and 2005 is not working very well. In my previous projects, the only way to get things working 100% was to recreate all pages in vs2005 and copy-paste the relevant code from the old solution.
If this post was useful to you, please mark it as answer. Thank you!
That is an absolute nightmare. In fact, if were not for the fact that sooner or later MS would abandon support for vs 2003 , I wouldn't ever persue this conversion avenue.
Anyone else with an approach to resolve this problem?
Thanks
Web Application Projectsvisual studio 2005asp.NET 2.0Response.redirectSessionIIS
Well for coversion, you could have followed manual conversion, because its not that straighforward. The other thing is do you really need to convert, because both 2003 i.e. 1.1 and 2.0 application can sit together. Another way is to leave the current app
as it is and develop any new ones in .net 2.0 and gradually convert but manually without using automation.
By the way how do you know that session ends on response.redirect?
Please Mark Post that helped you as answer, also include a summary of what solved the problem as it helps others in similar situations
I know the session ends because, I do cleanups in Session_End. The response.redirect uses a session-specific path that will no longer exist, hence failure.
It becomes extremely complex to maintain a web site using 2 development environments, and in addition have 2 development environments reside on the same machine. The scenario for disaster is that much greater. That, plus the fact that Visual Studio 2005
should as a base, be backwardly compatible, demands that the VS2005 Development Environment WORK.
visual studio 2005ASP.NETasp.NET 2.0web site projectResponse.redirectSessionIIS
I have determined that the Response.Redirect did not cause Session_termination, but that there is a problem in how
Directory.Delete or Directory.CreateDirectory is/are handled in Framework 2.0. The app under Framework 1.1 works fine.
Response.Redirect was the messenger, revealing what what was happening, at the eariest moment!!
Sorry, barking up the wrong tree. Session_End is the right tree.
Response.redirectsession.endSession and Authentication
None
0 Points
14 Posts
After porting working asp.net project to vs 2005, Response.Redirect ends Session
Aug 21, 2007 01:32 PM|StanDav|LINK
PROBLEM: Ported working vs2003 Asp.net project to VS2005. Response.Redirect terminates the session.
Environment: W2000 Advanced Server, IIS, vb.net
Both vs 2003 and vs2005 on same machine.
Changed the dll name to appname05.dll so that it would register
The appname is the same for vs2005 but the location and sitename in the iis was changed.I tried the following prior to ‘response.redirect’
Response.AddHeader("P3P", "CP=""CAO PSA OUR""")I tried entering the server path in the browser.Both to no avail.I tried some mods to the web.config such as the machine setting Request anyone experienced with this problem to please respond.visual studio 2005 ASP.NET asp.NET 2.0 web site project
Sdav
All-Star
16080 Points
3546 Posts
Re: After porting working asp.net project to vs 2005, Response.Redirect ends Session
Aug 21, 2007 02:37 PM|johram|LINK
Maybe if you use Server.Transfer instead of Response.Redirect?
To my knowledge, the conversion wizard between 2003 and 2005 is not working very well. In my previous projects, the only way to get things working 100% was to recreate all pages in vs2005 and copy-paste the relevant code from the old solution.
None
0 Points
14 Posts
Re: After porting working asp.net project to vs 2005, Response.Redirect ends Session
Aug 22, 2007 04:54 PM|StanDav|LINK
That is an absolute nightmare. In fact, if were not for the fact that sooner or later MS would abandon support for vs 2003 , I wouldn't ever persue this conversion avenue.
Anyone else with an approach to resolve this problem?
Thanks
Web Application Projects visual studio 2005 asp.NET 2.0 Response.redirect Session IIS
Sdav
Star
8693 Points
2975 Posts
Re: After porting working asp.net project to vs 2005, Response.Redirect ends Session
Aug 23, 2007 07:33 AM|naturehermit|LINK
Well for coversion, you could have followed manual conversion, because its not that straighforward. The other thing is do you really need to convert, because both 2003 i.e. 1.1 and 2.0 application can sit together. Another way is to leave the current app as it is and develop any new ones in .net 2.0 and gradually convert but manually without using automation.
By the way how do you know that session ends on response.redirect?
None
0 Points
14 Posts
Re: After porting working asp.net project to vs 2005, Response.Redirect ends Session
Aug 23, 2007 01:09 PM|StanDav|LINK
I know the session ends because, I do cleanups in Session_End. The response.redirect uses a session-specific path that will no longer exist, hence failure.
It becomes extremely complex to maintain a web site using 2 development environments, and in addition have 2 development environments reside on the same machine. The scenario for disaster is that much greater. That, plus the fact that Visual Studio 2005 should as a base, be backwardly compatible, demands that the VS2005 Development Environment WORK.
visual studio 2005 ASP.NET asp.NET 2.0 web site project Response.redirect Session IIS
Sdav
None
0 Points
14 Posts
Re: After porting working asp.net project to vs 2005, Response.Redirect ends Session
Aug 15, 2008 12:20 PM|StanDav|LINK
To ALL:
I have determined that the Response.Redirect did not cause Session_termination, but that there is a problem in how Directory.Delete or Directory.CreateDirectory is/are handled in Framework 2.0. The app under Framework 1.1 works fine.
Response.Redirect was the messenger, revealing what what was happening, at the eariest moment!!
Sorry, barking up the wrong tree. Session_End is the right tree.
Response.redirect session.end Session and Authentication
Sdav