My experience has been that T4 seems quite clunky and the development
experience just isn't there yet. There's no real integration of meta-data,
and I miss code-preserve blocks found in MyGeneration / Code Smith, etc.
Partial classes provide a solution - and it might just be me, but I find
them messy.

So far I've been using it for once-off code generation rather than
repetitive code generation I have with other tools. For example, the other
day I wanted to improve my error-handling in a code-generated
web-application. I changed my templates, and ran the batch file to
re-generate my project - and had my new error handling consistently applied
throughout my entire application.

Not saying this isn't possible in T4 - just it isn't as mature yet.



On Tue, Nov 16, 2010 at 10:20 AM, Preet Sangha <[email protected]>wrote:

> Interesting. Working with it is not easy I agree but large parts of our
> apps are based on it and it's great for model based development.
>
> On 16 November 2010 15:04, Nathan Schultz <[email protected]> wrote:
>
>> I'm still using MyGeneration. In fact I've written MyGeneration templates
>> to create 3 tier CRUD Web-Apps start to finish. Great for knocking out admin
>> screens.
>>
>> I'd advocate learning T4 though - while it's not quite there yet, it's
>> knowledge you'll be able to take into future versions of Visual Studio when
>> they get more things right with Code Generation.
>>
>>
>>
>>
>> On Tue, Nov 16, 2010 at 6:45 AM, Preet Sangha <[email protected]>wrote:
>>
>>> Start here: http://msdn.microsoft.com/en-us/library/bb126445.aspx
>>>
>>> Then when you have the idea then here.
>>>
>>> http://www.olegsych.com/tag/t4/ is a mine of info
>>>
>>>
>>>
>>> On 16 November 2010 11:30, Wolfgang Von Steinberg <[email protected]
>>> > wrote:
>>>
>>>> Thank you Preet,
>>>> any links on how to use T4? Is there something already there using T4
>>>> for this? I don't have time to reinvent the wheel ( badly ) if there is
>>>> already a solution.
>>>>
>>>> Regards
>>>>
>>>> WVS
>>>>
>>>> On Tue, Nov 16, 2010 at 9:24 AM, Preet Sangha <[email protected]>wrote:
>>>>
>>>>> This is where the T4 comes in. Use T4 to take the EF models and the DB
>>>>> structures and generate any Sps/views etc need.
>>>>>
>>>>> On 16 November 2010 11:21, Wolfgang Von Steinberg <
>>>>> [email protected]> wrote:
>>>>>
>>>>>> @Deepak: Thank you!
>>>>>>
>>>>>> @Filip: Thank you,
>>>>>> I am already using EF, but I have no control over the dynamically
>>>>>> executed sql. To solve that problem I am mapping the entities to SPs.
>>>>>>
>>>>>> @Martin:Thank you.
>>>>>>
>>>>>> Regards
>>>>>>
>>>>>> On Tue, Nov 16, 2010 at 9:07 AM, Filip Kratochvil <[email protected]
>>>>>> > wrote:
>>>>>>
>>>>>>> Hi Wolfgang,
>>>>>>>
>>>>>>> Have a look at T4 templating, there could be some templates available
>>>>>>> for that.
>>>>>>> MyGeneration (
>>>>>>> http://www.mygenerationsoftware.com/portal/default.aspx) also has
>>>>>>> this kind of functionality.
>>>>>>> Another option would be an ORM like NHibernate and then you don't
>>>>>>> have to worry about stored procs at all.
>>>>>>> Obviously it depends on your requirements.
>>>>>>>
>>>>>>> HTH,
>>>>>>> Filip
>>>>>>>
>>>>>>>
>>>>>>> On 16 November 2010 08:54, Wolfgang Von Steinberg <
>>>>>>> [email protected]> wrote:
>>>>>>>
>>>>>>>> Hello List
>>>>>>>>
>>>>>>>> Is there a easy way to generate Insert, Update , Delete and Select
>>>>>>>> stored procedures for each table in the database? using VS2010 or Sql 
>>>>>>>> Server
>>>>>>>> Management Studio or something else?
>>>>>>>> Doing it by hand is jsut grindingly stupid.
>>>>>>>>
>>>>>>>>
>>>>>>>> Thank you
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> regards,
>>>>> Preet, Overlooking the Ocean, Auckland
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> regards,
>>> Preet, Overlooking the Ocean, Auckland
>>>
>>
>>
>
>
> --
> regards,
> Preet, Overlooking the Ocean, Auckland
>

Reply via email to