2

After upgrading system from 2009 to 2013 SP1, the existing .net templates built with Tridion Content management dll 2009 and .net framework 3.5 are not executing (rendering fails)

When we run from template builder it gives follow error.

Debugging was started in process 'TcmTemplateDebugHost' with id 5396 Cannot find template class '-=NETASSEMBLY--.Templating.BuildingBlocks.DCPItem' in template assembly at Tridion.ContentManager.Templating.Assembly.AssemblyCache.GetTemplateType(Assembly templateAssembly, String className) at Tridion.ContentManager.Templating.Assembly.AssemblyCache.CachedAssemblyInfo.GetTemplate(String className) at Tridion.ContentManager.Templating.Assembly.AssemblyCache.GetCachedTemplateProcessor(String assemblyKey, String className) at Tridion.ContentManager.Templating.Assembly.AssemblyMediator.Transform(Engine engine, Template template, Package package) at Tridion.ContentManager.Templating.Assembly.CSharpSourceCodeMediator.RunTemplate(Engine engine, Package package, String templateUri, String className) at Tridion.Templating.CSharpTemplate.CSharpSourceTemplate.Transform(Engine __engine, Package __package) at Tridion.ContentManager.Templating.Assembly.CSharpSourceCodeMediator.Transform(Engine engine, Template template, Package package) at Tridion.ContentManager.Templating.Engine.ExecuteTemplate(Template template, Package package) at Tridion.ContentManager.Templating.Engine.InvokeTemplate(Package package, TemplateInvocation templateInvocation, Template template)
at Tridion.ContentManager.Templating.Compound.CompoundTemplateMediator.Transform(Engine engine, Template templateToTransform, Package package) at Tridion.ContentManager.Templating.Engine.ExecuteTemplate(Template template, Package package) at Tridion.ContentManager.Templating.Engine.InvokeTemplate(Package package, TemplateInvocation templateInvocation, Template template)
at Tridion.ContentManager.Templating.Engine.TransformItem(Template template, IdentifiableObject itemToRender) at Tridion.ContentManager.Templating.Debugging.DebuggingEngine.Run()
at Tridion.ContentManager.Templating.Debugging.DebugSession.Run()

Apart from that when we try to rebuild these old template using Tridion 2013 Content management dll and .net framework 4, it gives same error.

Later, there is one base tbb project, which we compilied again using Tridion 2013 Content management dll and .net framework 4 and now when we try to upload using TcmUploadAssembly it gives following error :

Error: Unable to load template assembly types Could not load file or assembly '--Base-TBB-Project--, Version=1.0.0.0, Cult ure=neutral, PublicKeyToken=1618c1322676f821' or one of its dependencies. The sy stem cannot find the file specified.

Has anyone faced similar issues before?

3 Answers 3

0

Might even be a problem with 32bit/64bit loading? Was your old platform 32 bits and your new platform 64?

Another thought that crossed my mind is that you might have a dependency on an assembly in the GAC that is missing on your new environment?

Could you try uploading the assembly into Tridion manually (to ensure that your TcmUploadAssembly problem is not an unrelated one)?

3
  • Yes old platform was 32 bit and new one is 64, we thought the same and so we decided to have fresh build of all .net assemblies with new Tridion 2013 CMS dll with .NET 4 and upload again. Somehow we are not able to upload via TCMUploadassembly but when we upload manually,it still gives same error while rendering that "Cannot find template class '--AssemblyDLL--.Templates.--Classname--' in template assembly"
    – user956
    Commented Mar 11, 2014 at 7:30
  • but does that className exist in your assembly?
    – Raj Kumar
    Commented Mar 11, 2014 at 7:47
  • When you say "Somehow we are not able to upload via TCMUploadassembly" can you confirm the error for this (or a link to another TREX quetsion) to review if this eludes to a shared issue? Commented Mar 11, 2014 at 10:13
1

You need to ensure following:

  • All the projects referenced in you TBB directly or indirectly should be re-build using latest Tridion Content Manager Dlls comes with 2013 - Which I guess you have already done as it seems your peoject is building up
  • The error message while uploading the TBB is self explanatory that one of the dependencies which means a DLL which either referenced directly or indirectly through some other DLL is not referenced correctly
  • It might also happen that there is stale reference to a DLL which is indeed not being used in the project at all - check the reference section of each and every project referenced in TBB and see if there is an un-referenced link of a DLL

I hope it helps

1

Please scan your project references.

Project References

  • Remove old references, clean your solution & Reference latest dlls of SDL tridion 2013 SP1
  • Update target framework to 4.0 of that project & compile
  • Double check all assembly versions via right click -> properties.
  • Scan for other custom dll, if any please open the source code of that dll, repeat step 1 to 3, compile and reference updated DLL.
2
  • As mentioned in problem, we have ensure that we have not missed anything among the steps you have mentioned
    – user956
    Commented Mar 11, 2014 at 7:33
  • When you upload any assembly, template building block templates are created for each template defined in that c# assembly(which you also use in any compound template). check that particular template is referring correct Dll version.
    – Raj Kumar
    Commented Mar 11, 2014 at 7:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.