简体   繁体   中英

Dynamic code Generation at compile time using c#

I need to generate code dynamically while building ac# project[compile time] without using T4 templates. I went through the questions already in stack overflow and all of them use T4 template. Is there a way to do it without using T4 templates? Please let me know. Thanks in advance.

I created a EXE for code generation using Code Dom and included it in VS Projects using the . In the targets file i referred my exe and when i compile my second project the .cs file gets generated automatically while building the project.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM