Close
Skip to content

Softwareproduction

Software Development Blog, mainly C# and .NET

  • ASP.NET Core
  • Mobile Development
  • Code Generation
  • General Programming
  • Development Tools
  • Servers
  • Miscellaneous

Tag: T4

Use T4 Templates For XSLT Transformation

September 20, 2013Munir HusseiniNo Comments

Suppose you have XSLT style sheets that produce some code from XML files. Now suppose you want to integrate these…

Read More 5787 views

Resolve Visual Studio Macros In VSIX Packages Or T4 Templates

September 18, 2013Munir HusseiniNo Comments

We all love Visual Studio Macros, right? Pre- and Post-Build actions or MSBuild scripts would get very nasty if there…

Read More 2745 views

Inheriting a T4 Template and Calling EnvDTE.DTE: The System Cannot Find The File Specified

September 16, 2013Munir Husseini2 Comments

Some strange behavior occurred today when I tried to encapsulate some functionality of a T4 template into a base class.…

Read More 4148 views

Get The ProjectItem of a T4 Template From Inside the T4 Template

June 10, 2013January 8, 2018Munir HusseiniNo Comments

So you got a T4 template and need access to the ProjectItem of that T4 template or to the parent…

Read More 3895 views

In-Memory Code Generation With .NET – Emit & Linq

February 17, 2013September 29, 2017Munir Husseini3 Comments
This entry is part 4 of 5 in the series In-Memory Code Generation With .NET

Instead of using templaing engines to create source code that need compilation, MSIL can be created using either Reflection Emit…

Read More 6740 views

In-Memory Code Generation With .NET – Compilation

February 17, 2013September 29, 2017Munir HusseiniNo Comments
This entry is part 3 of 5 in the series In-Memory Code Generation With .NET

In the previous article from this series, templating engines to generate .NET source code were presented. Once source code is…

Read More 9226 views

In-Memory Code Generation With .NET – Templating Engines

February 17, 2013September 28, 2017Munir HusseiniNo Comments
This entry is part 2 of 5 in the series In-Memory Code Generation With .NET

Templating engines allow a very flexible and quite easy, because human-readable definition of the code to be generated. Following, three…

Read More 6252 views

In-Memory Code Generation With .NET – Models

February 17, 2013September 28, 2017Munir HusseiniNo Comments
This entry is part 1 of 5 in the series In-Memory Code Generation With .NET

In this series, I will show how to generate, compile and load .NET code at runtime using different techniques.

Read More 4167 views

Code Generation And Manipulation Using T4 Templates And Visual Studio Automation By Sample

May 15, 2012January 11, 2018Munir HusseiniNo Comments

Introduction The goal of this exercise is to generate a class that inherits from System.Data.Entity.DbContext. It will contain properties of type System.Data.Entity.DbSet for…

Read More 4958 views
(c) 2011-2020 Munir Husseini