5

I am following this blog post.

It says that you need to deploy the referenced dll's to the Tridion bin folder but when running my TBB in Template Builder it can't find/load the dll's.

I can't find a decent answer if it's possible to do so or that it is mandatory to deploy them in the GAC - that's something I'd rather not do.

Can someone who has experience with referencing third party dll's from a TBB shed some light on this matter please?

[added]

As you can see in the binding information it's only looking in the templating directory. I would have suspected it to look in Tridion\Bin. Created a folder in the templating dir for the YUI Compressor so it's loading that one but there must be another way.

=== Pre-bind state information ===
LOG: User = NT AUTHORITY\NETWORK SERVICE
LOG: DisplayName = EcmaScript.NET, Version=1.0.1.0, Culture=neutral, PublicKeyToken=null
 (Fully-specified)
LOG: Appbase = file:///c:/program files (x86)/Tridion/templating/
LOG: Initial PrivatePath = NULL
LOG: Dynamic Base = NULL
LOG: Cache Base = NULL
LOG: AppName = TcmTemplateDebugHost.exe
Calling assembly : Yahoo.Yui.Compressor, Version=2.4.0.0, Culture=neutral, PublicKeyToken=null.
===
LOG: This bind starts in default load context.
LOG: Using application configuration file: c:\program files (x86)\Tridion\templating\TcmTemplateDebugHost.exe.Config
LOG: Using host configuration file: 
LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework64\v4.0.30319\config\machine.config.
LOG: Policy not being applied to reference at this time (private, custom, partial, or location-based assembly bind).
LOG: Attempting download of new URL file:///c:/program files (x86)/Tridion/templating/EcmaScript.NET.DLL.
LOG: Attempting download of new URL file:///c:/program files (x86)/Tridion/templating/EcmaScript.NET/EcmaScript.NET.DLL.
LOG: Attempting download of new URL file:///c:/program files (x86)/Tridion/templating/EcmaScript.NET.EXE.
LOG: Attempting download of new URL file:///c:/program files (x86)/Tridion/templating/EcmaScript.NET/EcmaScript.NET.EXE.
LOG: All probing URLs attempted and failed.
2
  • Did you restart everything once you'd placed the files in the \bin folder? – Rob Stevenson-Leggett May 21 '14 at 9:17
  • Yes the whole shabang. Services, COM+, and IISReset. I can see in the Assembly Binding Log Viewer that it's looking in the templating directory for the dll's – Ryan Van Der Wal May 21 '14 at 12:19
3

Looks like you've solved it. If you were executing your template via publishing, then, IIRC the DLLs should be in Tridion/bin or GAC. However, Template Builder looks for them, as you found out, in the /templating directory.

In my implementation as per the blog post, I believe we put the third-party assembly in the GAC.

4
2

We had a similar issue of referring a 3rd party DLL from the templating code. Instead of putting the 3rd party DLL in GAC which requires approvals from the clients, we used ILMerge to merge the 3rd party DLL and the templating DLL.

This works perfect.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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