BEST
DEALS
OF THE
YEAR!
SAVE UP TO $3,000
24 NOV
1 DEC
00 Days
00 Hrs
00 Min
00 Sec
Open Closed

Execute custom code after user login / commercial module #6390


User avatar
0
rferrarin created
  • ABP Framework version: v7.4.4
  • UI Type: Blazor Server
  • Database System: EF Core (SQL Server)
  • **Tiered: no

Hi, I need to execute some custom code after the user has succesfully logged in the system (basically I need to load some user-dependent constants) I couldn't find any info about doing this, can you help me? Best regards


1 Answer(s)
  • User Avatar
    0
    liangshiwei created
    Fullstack Developer

    You can try this:

    context.Services.ConfigureApplicationCookie(options =>
    {
        options.Events.OnSignedIn = async signedContext =>
        {
            var userId= signedContext.Principal.Identity.FindUserId();
        };
    });
    
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.1.0-preview. Updated on November 20, 2025, 09:12
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.