1

I have a webforms project and an MVC project but the login is only one that is through the webforms project. In the home page, we gave the user to select the project either MVC or web forms, if the user selects the MVC project then we are redirecting to MVC project but the real problem came at the time of authorization.

I am unable to get the session variable from Web forms to MVC

I am using SQLServer mode and cookies enabled

Please help me in this

Thanks

arun sai
  • 23
  • 7
  • 1
    I think your solution is here: https://stackoverflow.com/questions/2868316/sharing-sessions-across-applications-using-the-asp-net-session-state-service – Roberto Conte Rosito Jun 14 '18 at 07:48
  • tnx for the reply @RobertoConteRosito I am able to get the session id same for both application but the session variable that I have created in the web application like Session["LoggedInUser"] this session variable I cannot get in my MVC application – arun sai Jun 14 '18 at 07:51
  • Have you changed the session config in web.config? This is the most important part. Two applications needs to share same key to detect the same sharing data. – Roberto Conte Rosito Jun 14 '18 at 07:55
  • @RobertoConteRosito can you please elaborate so that it would be very helpful for me – arun sai Jun 14 '18 at 08:15
  • @RobertoConteRosito your first answer solved my problem thank you – arun sai Jun 14 '18 at 09:05

0 Answers0