Hi Satish,
code to use assemblies in the T4 Template:
If you want to user the System.dll in your T4 template, below need to be included in yout T4 template:
<#@
Assembly name="System.dll" #>
<#@
Import Namespace="System" #>
Code to have assemblies that would be used in the generated code:
For this simply you need to add the assemblies with using statement. If you want to user the System.dll, it would be
using
System;
using
System.Data;
using
System.Configuration;
using
System.Collections;
NOTE: If you are refering the assemblies with using statements in the code file, make sure that you have taken reference to those aseemblies from GAC or other folders. If not, even though you write the using statements, the code will not be active.
Regards,
-Noor