CodeSmith Community
Your Code. Your Way. Faster!

CodeSmith Project Tutorial

Latest post 04-17-2007 4:05 PM by Geet. 3 replies.
  • 03-01-2007 8:43 AM

    CodeSmith Project Tutorial

              Hi! I'm a newbie inCodeSmitn, I started 2 week ago. I learned how to make templates whith the tutorials ,and made some templates to generate bases of DAL and BLL for an application. But i don't understand how to use it after: I explain: My templates are OK, they generate the code i want from one table, but i have more than 60 tables, so want to automate the generation: for example, with 3 temples and 60 tables, apply the templates to the table to obtain 180  files named  TemplateNameTableName.cs. I understand i had to do this with Code Smith Project, but after reading Introduction to CodeSmith Project Files and look after other tutorials or information, i still didn't know how to do.

            Could someone explain it to me please? I guess than it could be usefull for otherone too.
     

    Thank You, Michael Jacob. 


     

    • Post Points: 35
  • 03-01-2007 7:50 PM In reply to

    • pwelter34
    • Top 25 Contributor
    • Joined on 03-13-2003
    • Eden Prairie, MN
    • Posts 255
    • Points 680,955

    Re: CodeSmith Project Tutorial

    Hi,

    You need to create a csp file.  Once you have a csp file, you can use the Manage Outputs options by right clicking it.  This will allow you to select a template and output for that template.  You can copy that output and change the output name and some properties for each table you need.  This will allow you to generate all the output files in a batch.

    ~ Paul 

    • Post Points: 65
  • 03-17-2007 12:06 PM In reply to

    Re: CodeSmith Project Tutorial

    Thank you. Does anybody have a sample yet?

    I have 3 cst-files: dal, class and a sp template. I would like to select multiple tables and then generate *.cs for every of my tempates? How to do?

    Any help or sample would be greatful.

    • Post Points: 5
  • 04-17-2007 4:05 PM In reply to

    • Geet
    • Not Ranked
    • Joined on 04-17-2007
    • Posts 1
    • Points 5

    Re: CodeSmith Project Tutorial

    Hi,

    Can you pls tell what template(s) to select for creating DAL.

    Thanks

    G

    • Post Points: 5
Page 1 of 1 (4 items) | RSS
Copyright © 2008 CodeSmith Tools, LLC
Powered by Community Server (Commercial Edition), by Telligent Systems