1
Vote

Can't use the Visual Studio macros in the include directives

description

Like $(ProjectDir) or $(SolutionDir).
 
<#@ include file="$(ProjectDir)T4\T1.ttinclude" #>
I am getting an error:
 
Error 4 A namespace cannot directly contain members such as fields or methods
 
But when I use:
<#@ include file="..\T4\T1.ttinclude" #>
 
It's OK.

comments

sandermvanvliet wrote Nov 8, 2012 at 9:23 AM

VisualStudio macros are not supported in the template files yet

wrote Feb 13, 2013 at 4:44 AM