title: T4 templates error: loading the include file ef.utility.cs.ttinclude returned a null or empty string
body: <p>I have overridden the controller generation T4 templates (<code>ControllerWithContext.tt</code>) as described <a href="http://blogs.msdn.com/b/webdevtools/archive/2009/01/29/t4-templates-a-quick-start-guide-for-asp-net-mvc-developers.aspx">here</a>.<br>
  I would like to take advantage of the code helper utilities found in <code>EF.utility.CS.ttinclude</code> as used in the POCO model generator T4 template.  Therefore I copied the following lines from my <code>Model.tt</code> to my <code>ControllerWithContext.tt</code>.</p>
  
  <pre><code>&lt;#@ include file="EF.Utility.CS.ttinclude"#&gt;
  </code></pre>
  
  <p>However, when I try to add a controller I am getting the error message</p>
  
  <blockquote>
    <p>Loading the include file 'EF.utility.CS.ttinclude' returned a null or empty string</p>
  </blockquote>
  
  <p>According to the <a href="http://msdn.microsoft.com/en-us/library/bb126242.aspx">MSDN documentation</a>, this error is because the included file is blank, which it clearly isn't because it works with <code>Model.tt</code></p>
  
  <p>The only difference I can see is that the overridden <code>ControllerWithContext.tt</code> does not have a Custom Tool defined, whereas the <code>Model.tt</code> has it set to <code>TextTemplatingFileGenerator</code>.</p>
  
  <p>My workaround is to copy the functions I need from <code>ef.utility.cs.ttinclude</code> into my <code>ControllerWithContext.tt</code>, which in itself threw up more errors but which were easily solved.</p>
  
  <p>How can I include T4 templates without a custom tool defined?</p>