Error Scaffolding with MvcMailer in MVC 4

mvcmailer

Solution

I had the same issue, to fix it I updated the Scaffolding packages (T4 in one occasion, T4 + MVCScaffolding on another), and restarted VS.

update-package T4Scaffolding

and / or

Update-Package MvcScaffolding

remember to restart VS afterward.

Problem

I'm trying to get MvcMailer working in a new MVC 4 Beta project (created just for trying this out), using the latest version of NuGet. I get to the step PM> Scaffold Mailer UserMailer Welcome,PasswordReset At which point I see the error message: Cannot resolve alias 'Scaffold' because it refers to term 'Invoke-Scaffolder', which is not recognized as a cmdlet, function, operable program, or script file. Verify the term and try again. At line:1 char:9 + Scaffold <<<< Mailer UserMailer Welcome,PasswordReset + CategoryInfo : ObjectNotFound: (Scaffold:String) [], CommandNotFoundException + FullyQualifiedErrorId : AliasNotResolvedException Update: After installing MvcScaffolding (wasn't a NuGet prerequisite...), the error message for the same command changes to: Invoke-Scaffolder : A positional parameter cannot be found that accepts argument 'UserMailer'. At line:1 char:9 + Scaffold <<<< Mailer UserMailer Welcome,PasswordReset + CategoryInfo : InvalidArgument: (:) [Invoke-Scaffolder], ParameterBindingException + FullyQualifiedErrorId : PositionalParameterNotFound,T4Scaffolding.Cmdlets.InvokeScaffolderCmdlet How can I resolve this issue?

Original source

Related problems