对于意见ASP.NET MVC的自定义T4模板 [英] ASP.NET MVC custom T4 templates for views

查看:232
本文介绍了对于意见ASP.NET MVC的自定义T4模板的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我加入一个新的强类型的视图一个ASP.NET MVC项目,我可以查看不同内容模板(详细信息创建,编辑列表)之间进行选择。我已阅读这些都是基于Visual Studio的T4 code生成引擎模板。

When I'm adding a new strongly-typed view to an ASP.NET MVC project, I can select between different view content templates (Create Details, Edit, List). I have read these are templates based on the Visual Studio T4 code generation engine.

如何才能创作和配置我自己的模板,让添加一个新的视图时,它们出现在可用的模板?

How can I author and configure my own templates and let them appear in the available templates when adding a new view?

推荐答案

ASP.Net MVC - T4玩转

<一个href=\"http://blogs.msdn.com/webdevtools/archive/2009/01/29/t4-templates-a-quick-start-guide-for-asp-net-mvc-developers.aspx\"相对=nofollow> T4模板:一个快速入门指南ASP.NET MVC开发

这篇关于对于意见ASP.NET MVC的自定义T4模板的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆