© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#•3y ago•
1 reply
mazino

Issue with AddUserStore in asp.net core

Hi. I have an issue with the following line of code in asp.net core
builder.Services.AddIdentityCore<ApplicationUser>(options => options.SignIn.RequireConfirmedAccount = true)
    .AddUserStore<ApplicationDbContext>();
builder.Services.AddIdentityCore<ApplicationUser>(options => options.SignIn.RequireConfirmedAccount = true)
    .AddUserStore<ApplicationDbContext>();

I get this error
ArgumentException: Implementation type 'WebApplication1.ApplicationDbContext' can't be converted to service type 'Microsoft.AspNetCore.Identity.IUserStore
ArgumentException: Implementation type 'WebApplication1.ApplicationDbContext' can't be converted to service type 'Microsoft.AspNetCore.Identity.IUserStore

(Im following the tutorial at this page)
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Routing issue with ASP.Net Core
C#CC# / help
4y ago
ASP.NET Core | Issue with in-memory data removal
C#CC# / help
4y ago
svelte with asp.net core
C#CC# / help
2y ago