Can't use nested includes.

Jul 24, 2012 at 4:56 AM

For example:

 

file1_1.ttinclude

<#@ template language="C#" hostspecific="True" #>
<#@ import namespace="System.Text" #>

<#+
    void GenerateMe1_1()
    {
        this.Write("text1_1");
    }
#>

 

file1.ttinclude

<#@ template language="C#" hostspecific="True" #>
<#@ import namespace="System.Text" #> <#@ include file="file1_1.ttinclude" #> <#+ void GenerateMe1() { this.Write("text1"); } #>

 

maintest.tt

 

<#@ template language="C#" hostspecific="True" #>
<#@ include file="file1.ttinclude" #>
<#
    GenerateMe1();
    GenerateMe1_1();
#>

 

 I have error:

Error 18 The name 'GenerateMe1_1' does not exist in the current context