Share session data in the new WiseJ-3 release and .NET 6.0 asp.net core

0
0

I was wondering if there is a new way to make this work with WiseJ-3 since HttpContext.Current is no longer there, something like IHttpContextAccessor or getting existing IServiceProvider registrations from WebApplication.CreateBuilder?
https://wisej.com/support/question/share-session-data-from-wisej-controls-to-net

  • You must to post comments
0
0

Do you have an example for #2. The comment might have been cut off.

Essentially if I can access the asp.net core ServiceProvider from within WiseJ I think that would solve my issue, as I really don’t need the HttpContext I was just thinking it would be an easier way to share data.

  • You must to post comments
0
0

Hi Marik,

There are a couple of solutions to your issue:

  1. Use Microsoft.AspNetCore.SystemWebAdapters, it’s a NuGet package that adds System.Web to .NET Core with an idential class library as .NET Framework.
    You can click here for an example of how to use it.
  2. You can simply use Microsoft.AspNetCore.Http.HttpContextAccessor, i.e. Microsoft.AspNetCore.Http.HttpContextAccessor a = new(); a.HttpContext..

HTH,
Alaa

  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.