Error creating class from TT

Topics: General Discussion Forum, Service Factory Modeling Edition Forum
Sep 10, 2007 at 8:33 PM
I'm trying to generate a simple class from a text template. Using a simple recipe. I'm receiving the following error when the GenerateClass action is executed. The GenerateClass action uses the TextTemplateAction.

Any ideas would be greatly appreciated.

Thanks ,
Jeff

Microsoft.Practices.RecipeFramework.ActionExecutionException: An exception occurred during the binding of reference or execution of recipe CreatePartial. Error was: Action GenerateClass failed to execute:
Exception of type 'Microsoft.Practices.RecipeFramework.VisualStudio.Library.Templates.TemplateException' was thrown..
You can remove the reference to this recipe through the Guidance Package Manager. ---> Compiling transformation: Metadata file 'Microsoft.Practices.ServiceFactory.DataContracts.Dsl, Version=1.0.0.0, Culture=neutral, PublicKeyToken=7e39fddf3e20b4e4' could not be found
----------------------------------------------------------------------------------------------------
Compiling transformation: Metadata file 'Microsoft.Practices.ServiceFactory.Extenders.DataContract.Wcf, Version=1.0.0.0, Culture=neutral, PublicKeyToken=7e39fddf3e20b4e4' could not be found
----------------------------------------------------------------------------------------------------
Compiling transformation: Metadata file 'Microsoft.Practices.ServiceFactory.ServiceContracts.Dsl, Version=1.0.0.0, Culture=neutral, PublicKeyToken=7e39fddf3e20b4e4' could not be found
----------------------------------------------------------------------------------------------------
Compiling transformation: Metadata file 'System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' could not be found
----------------------------------------------------------------------------------------------------

--- End of inner exception stack trace ---
at Microsoft.Practices.RecipeFramework.Recipe.UndoExecutedActionsAndRethrow(Exception ex)
at Microsoft.Practices.RecipeFramework.Recipe.ExecuteActions(IDictionaryService readOnlyArguments, IDictionaryService arguments, ITypeResolutionService resolution)
at Microsoft.Practices.RecipeFramework.Recipe.Execute(Boolean allowSuspend)
at Microsoft.Practices.RecipeFramework.GuidancePackage.Execute(String recipe, IAssetReference reference, IDictionary arguments)
at Microsoft.Practices.RecipeFramework.GuidancePackage.Execute(IAssetReference reference)
at Microsoft.Practices.RecipeFramework.RecipeReference.OnExecute()
at Microsoft.Practices.RecipeFramework.AssetReference.Execute()
at Microsoft.Practices.RecipeFramework.VisualStudio.RecipeMenuCommand.OnExec()
at Microsoft.Practices.RecipeFramework.VisualStudio.AssetMenuCommand.Invoke()
Sep 11, 2007 at 4:49 PM
I answered my own question. From looking at Jelle Druyts blog I learned that you have to provide the full path to the assembly. This is why the file not found errors were being thrown. Regardless I wasn't using the assemblies in question so I shouldn't have had the reference in the tt in the first place.

I got myself into this issue by copying and pasting the tt from the TypeTranslator.tt.