title: How to Debug System.NullReferenceException When Running Transformation?
body: <p>I am attempting to generate code using T4 Text Templating, but when running the script, I get the error below:</p>
  
  <pre>Running transformation: System.NullReferenceException: Object reference not set to an instance of an object.
     at Microsoft.VisualStudio.TextTemplatingB0A58A4C85EA3D7032675015C6052C89.GeneratedTextTransformation.TransformText()
     at Microsoft.VisualStudio.TextTemplating.TransformationRunner.RunTransformation(TemplateProcessingSession session, String source, ITextTemplatingEngineHost host, String& result)</pre>
  
  <p>As I am unfamiliar with T4, I'm not sure exactly where to look to resolve this issue.</p>