code smith error configuring using template


I inherited a project, it uses Code Smith Generator, every time I try to configure a new project using the existing templates.

Using VS 2017

I get this error, note NHibernateHelper is in the project

System.IO.FileNotFoundException: Could not load file or assembly 'CodeSmith.Engine, Version=, Culture=neutral, PublicKeyToken=9fd61cdb91609a7a' or one of its dependencies. The system cannot find the file specified.
File name: 'CodeSmith.Engine, Version=, Culture=neutral, PublicKeyToken=9fd61cdb91609a7a'
   at System.Reflection.RuntimeAssembly.GetType(RuntimeAssembly assembly, String name, Boolean throwOnError, Boolean ignoreCase, ObjectHandleOnStack type)
   at System.Reflection.RuntimeAssembly.GetType(String name, Boolean throwOnError, Boolean ignoreCase)
   at CodeSmith.Engine.CompileTemplateResult.#ZLb.#YLb()
   at CodeSmith.Core.Extensions.RetryUtil.Retry(Action action, Int32 attempts, Int32 retryTimeout)
   at CodeSmith.Engine.CompileTemplateResult.CreateTemplateInstance()
   at CodeSmith.Engine.CodeTemplateCompiler.CreateInstance()
   at CodeSmith.Gui.AddOutput.#pm(String #Ucb)

=== Pre-bind state information ===
LOG: DisplayName = CodeSmith.Engine, Version=, Culture=neutral, PublicKeyToken=9fd61cdb91609a7a
LOG: Initial PrivatePath = bin;AddIns;SchemaProviders
Calling assembly : NHibernateHelper, Version=, Culture=neutral, PublicKeyToken=null.

=== LOG: This bind starts in LoadFrom load context. WRN: Native image will not be probed in LoadFrom context. Native image will only be probed in default load context, like with Assembly.Load(). LOG: Using application configuration file: C:\Users\CHINASYNDROME\AppData\Local\Microsoft\VisualStudio\15.0_77daa9ec\devenv.exe.config LOG: Using host configuration file: LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework\v4.0.30319\config\machine.config. LOG: The same bind was seen before, and was failed with hr = 0x80070002.

asked on Stack Overflow May 15, 2019 by China Syndrome

0 Answers

Nobody has answered this question yet.

User contributions licensed under CC BY-SA 3.0