Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 613
  • Last Modified:

Classic ASP to ASP.NET

I have read many articles and post about sharing sessions with classic asp and the newer asp.net.  I am having trouble with any of them that I have read on how to do.  Basically I have a user site where they log into the website on an HTML page, that when verified they are passed to a .asp dashboard page.  I am currently putting forms on the .asp site that are in asp.net, but I need to verify that they are who they really say they are.  So when the user clicks on a link from a .asp page to go to a specific asp.net form I want the form to open up in a new tab and somehow send the username with it(hidden username in a field) so that when I receive the form it show's who sent it.  I am currently coding in C# for my asp.net files.
2 Solutions
Don't use sessions, create a cookie, then read the cookie in the .net page and place in a session.
The Best way is use a database table.

when you are switching from asp to asp.net then store the session values from asp to a database table.

Redirect to aspx page with session id as querystring. the aspx page will read the session details from database and restore it in asp.net session.

We have tried many methods in past but this method still works like a charm.

You need to design your architecture in such a way that there is a transition page in between.

A Transition page can take page name & Session id as querystring. also store the details in database and can read the details from database. You may need 2 such pages - 1 for asp and 1 for aspx.

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now