I have a T4 template that generates classes from an xml file.
How can I add a dependency between the xml file and the template file so that when the xml file is mod
I don't believe T4 supports automatic template transformation based on an external dependency. I agree with Marc - if you only have one external file, you could create a custom "custom tool" for your XML file or simply use ttxgen. However, I don't think this approach scales up to a scenario where t4 template depends on more than one file. You may need to create a Visual Studio package to handle that.