Scaffold identity fails with Visual Studio 2019

I created a blazor web assembly using the Syncfusion template and then tried to scaffold identity and it fails with a meaningless error message. I would appreciate some guidance on how to scaffold identity so that I can do login authentication.

I tried to use the cli and this also failed saying I already had a dbContext

I have the latest Visual Studio 2019 with all patches and updated all nuget packages.

I have the latest syncfusion.

I setup the blazor webassembly to use sql server express locally installed.

the template app compiles and runs, I can register and login.

I need to move to email authentication but cannot.


2 Replies

MG Mark Gregory September 27, 2021 11:45 PM UTC

I created a new project with only one syncfusion control included, tried to scaffold identity and it worked.

So in this case the answer is to scaffold immediately and not at the point where you're guided to do so if you're following the Microsoft guide on how to do registration email authentication.


I'll now compare the old project and this one to see what the differences are and to find a way forward.



JL Joshna Lingala Uthama Reddy Lingala Syncfusion Team September 28, 2021 04:11 PM UTC

Hi Mark, 
 
Greetings from Syncfusion. 
 
We have validated the reported issue “ scaffolding with Syncfusion template didn’t work in Visual Studio 2019” at our end. We suspect that the required packages for adding scaffolding identity might have missed at you end which may cause the issue. Please install the following packages before adding scaffolding identity to the project. 
                                  Microsoft.AspNetCore.Identity.UI 
                                  Microsoft.EntityFrameworkCore.Design 
 
Kindly install the packages and then add the scaffolding identity to the project and get back to us if you need further assistance. 
 
Regards, 
Joshna L 
 


Loader.
Up arrow icon