Your code. Your way. Faster.
What is CodeSmith Generator?
CodeSmith Generator is a software development tool to help you get your job done faster. Technically speaking it is a template driven source code generator that automates the creation of common application source code for any language (C#, Java, VB, PHP, ASP.NET, SQL, etc.). CodeSmith Generator includes many useful templates as well as entire sets of templates for generating proven architectures. You can easily modify any templates or write your own to generate your code exactly the way you want it.
CodeSmith Generator's syntax is almost identical to ASP.NET. So if you are familiar with ASP.NET then you should be able to quickly learn the template syntax. You can use the C# or VB.NET languages in your templates and your templates can output any ASCII-based (text based) language.
What can CodeSmith Generator do for you?
CodeSmith Generator can help you produce higher-quality, more consistent code in less time and enables software developers to efficiently:
- Reduce repetitive coding.
- Generate your code in less time with fewer bugs.
- Produce consistent code that adheres to your standards.
- Create your own custom templates for any language.
What Our Customers Say...
"I don't know if I necessarily want to let this get out or not but I just started using CodeSmith and I generated 49,533 lines of accurate ready to use C# source code in my first 15 hours of CodeSmith usage. Primarily most of the 15 hours was just my time learning the product. Otherwise I could have done it in about 15 minutes. I can't believe I use to code some of this by hand. Thanks for the great tool!"
~ Matt Ferguson
"Indeed a great tool for programmers!!!
Two thumbs up..."
"CodeSmith is amazing! Code generation saved us hundreds of man hours and creates less error prone code."
~ Scott Cate
"CodeSmith is the .NET codegen tool that I wish I'd invented."
~ Chris Sells
"Development is a Breeze with CodeSmith"
Web World Experts
To download CodeSmith Generator, please visit the downloads page.
When downloading for the first time you will be asked to register for a trial of Generator. If you are already registered, you may login to skip this step and go straight to the download!
A Generator license includes batch code generation, template caching, Visual Studio integration, ActiveSnippets, the ability to use the Generator API in custom internal applications, and merging support. From small to large complex code generation scenarios Generator is the perfect tool.
For use by a single developer.
Use the API, MSBuild tasks, or console client on a server or build machine. Does not include a GUI client.
The SDK Edition enables distribution of custom applications that use the Generator API (including SchemaExplorer). These applications can make use of the full power of the Generator engine in a programmatic fashion. You will be able to distribute the Generator assemblies with your application and include a runtime SDK license either in your application folder or shared license folder.
SDK License, $1,499
A SDK license allows access to the Generator Engine for an internal application.
Commercial SDK License, $2,999
The Commercial SDK license allows access to the Generator Engine to be used in an approved commercial application royalty free.
Please contact Sales for SDK restrictions and pricing.
Enterprise licensing for CodeSmith Generator is available for large companies who want to give all of the developers access to the Generator.
Site License, $2,999
The Site license provides you with a license for 25 developers for use at a single location of your enterprise.
Enterprise License, $4,999
The Enterprise license provides you with unlimited licenses for use at any location within your enterprise.
For a complete feature chart that describes the differences between professional and standard, please view our features section.
You can purchase CodeSmith Generator from our online store via credit card or purchase order.
When placing an order for 3 or more licenses of CodeSmith Professional or CodeSmith Standard, you automatically qualify for the following discount rates. Your discount will automatically appear on your CodeSmith Tools Store quote / purchase price:
15% discount for 3 or more licenses
20% discount for 5 or more licenses
30% discount for 10 or more licenses
CodeSmith Generator customers who have Premier Support are eligible for a free upgrade to the latest version. For customers without Premier Support, the upgrade fees are as follows:
- Generator 6.5 to Generator 8.0, $149
- Professional 3.x or 4.x or 5.x or 6.0 Legacy to Generator 8.0, $209
- Standard 5.x to Generator 8.0, $249
- Standard 3.x or 4.x Legacy to Generator 8.x, $259
Major versions of CodeSmith Generator always include bug fixes, performance enhancements, and new features. Keeping your copy of the Generator updated always ensures you will be getting the fastest, most reliable, and feature complete experience that we have to offer. Using the latest version also enables our support team to assist you with any problems that you may experience more quickly.
Also, some of the official Generator Frameworks require the latest version of the Generator. This means that keeping up to date with the Generator allows you to stay up to date with your templates, and provides you with access to their fixes and enhancements as well.
Don't wait to get access to the latest bug fixes, performance enhancements, and new features!
This table shows the features included in the different versions of CodeSmith Generator. Please use this as a guide to determine which version is most suitable for your needs.
|Feature||Generator||Generator SDK||Generator Server|
|Simple Template Syntax The template syntax is almost identical to ASP.NET. So if you are familiar with ASP.NET then you should be able to quickly learn the template syntax.|
|Execute Custom Templates Create your own templates and execute them.|
|Auto SQL Script Execution Templates that generate SQL scripts can be auto-executed after generation allowing for easy deployment of generated SQL code.|
|Extensible Metadata Generate from any data source.|
|SchemaExplorer Schema Discovery API An API that makes it very easy to work with Database Objects.|
|Rich XML Support The XmlProperty directive allows you to easily use XML to drive your templates. If an XSD schema is provided, a strongly typed XML object model will automatically be generated and makes working with XML simple. If an XSD schema is not provided Generator will allow you to work directly with an XmlDocument instance instead. Combined with the IntelliSense capabilities, this feature makes working with complex XML a breeze.|
|Sub Template Support Save time by putting common code in a sub template.|
|Useful Sample Templates Sample templates that show you how easy it is to create your custom templates.|
|Console Client The console client allows you to easily automate your code generation process and can execute templates one at a time or in batches.|
|Template Explorer Client Explorer Client allows for quick generation of a template.|
|Template Editor A Visual Studio Integrated editor that allows you to quickly create or edit a template. It features IntelliSense and many other features.|
|Template IntelliSense Generator template editor includes statement completion for your custom templates.|
|Generator Map Support Reduces the amount of plumbing code in their templates and increase the readability and re usability at the same time. Maps provide a named dictionary like semantic to template development.|
|Visual Studio Integration Generator Integration for template execution within Visual Studio is a first class concept with support for CodeSmith Project Integration, Generate OnBuild features, MS-Build Integration, and drag and drop templates onto the code surface.|
|Generator API Direct access to the API for generating outside of CodeSmith's various integration points.|
|Template Caching Caches the compiled templates which cuts down on the time it takes to generate.|
|Template Debugging Generator makes it easy to debug your templates by providing the template developer with the line number in the template where the problem occurred.|
|Merge Capabilities The merging capabilities in Generator allow you to merge generated and hand written code within a single file|
|Generator Project Support Whether you are working with Visual Studio, MSBuild, Windows Explorer, a command line / batch file, or Generator itself, Generator Projects makes automating your code generation process easy and consistent.|
|MSBuild Support Generate your templates during your build process.|
|ActiveSnippet Support Imagine Visual Studio 2013 snippets, but with the full power of Generator available to execute any logic or access any complex metadata (including database schema and xml data) to control the output of your snippets.|
Visual Studio Integration
The tight integration with Visual Studio allows you to fully manage template execution right from Visual Studio! This means you can maintain a high Code Generation presence right within Visual Studio and not have to switch applications to run code generation.
CodeSmith Generator integrates with Visual Studio
The XmlProperty directive gives you a strongly-typed object model and statement completion for metadata stored in XML files. Generator allows you to store metadata in external XML files. To incorporate XML metadata into your templates, you use an XmlProperty directive. Watch as we show some cool ways to get the most out of xml properties.
Generate your code while preserving custom code. Generator supports both Preserve and Merge functionality on any text based output using regions.
CodeSmith Generator ships with a complete template set that helps you get up and running in no time flat. These template sets include ActiveSnippet Templates, Database Templates, Example Templates, Framework Templates and various other templates. Why waste time with repetitive tasks? Use ActiveSnippets and focus on other parts of your application.
ActiveSnippet's allow you to quickly reduce the amount of time it takes to get your job done. Any template can be used as an ActiveSnippet. CodeSmith Generator ships with active snippets that will speed up the process of creating custom events and exceptions. Also you can quickly generate an enumeration or properties from database meta data.
Learn more by watching the ActiveSnippet Overview Video.
Whether you are looking for an easier ways to create a business object, document your database, script your table data, execute or create stored procedures, generator is here to save you time and headaches.
The Business Object template is a template that is a great template to use if your looking to quickly create an entity for your project. Many developers also use this template as a base template when they need to create a new POCO (Plain Old CLR Object), Data Transfer Object or Domain Class template.
The Script Table Data and Extended Properties template allows you to generate a SQL script that can be used to migrate your data between database servers or import existing data into newly created databases.
The DbDocumenter template will create a nicely formatted html document of your entire database.
The Stored Procedure template will create (Insert, Update, Delete, Select) Stored Procedures based on a Database Table. Everything is configurable to fit your unique requirements.
The Command Wrapper template will create a wrapper around any SQL Stored Procedure or SQL Function. An easy to use API allows you to execute a stored procedure or function by calling Execute() which will return get back a strongly typed object or result. When used in conjunction with the Stored Procedure templates, you can quickly get data from your database.
The Typed DataSet template creates typed DataSet and DataAdapter classes based on a database table of your choosing.
We provide a set of example templates that demonstrate how to use various Generator features in your own custom template.
The ASP.NET folder contains a template that will show you how to use Master Templates that will generate an ASP.NET default.aspx page. (Watch the Master Templates Video)
The Basic Samples folder contains templates that display the use of Master Templates, Partial templates and Linq To Objects in your templates.
The Maps folder is a great example on how and when to use CodeSmith Generator Maps.
The Merge folder contains templates that will show you how to use Preserve Region and Insert Region Merge Strategies across different file types and languages. (Watch the Merge Strategies Video)
The Photo Gallery folder contains templates combine using a Master Templates and code behind to create a generic photo gallery from a directory of image files.
The Xml folder contains templates that show you how to generate from an Xml data source using the XmlProperty. (Watch the XmlProperty Video)
The Other templates folder contains various templates that ease the use working with AJAX, Custom Collections (ArrayList, HashTable, Queues, SortedList and more) and WIX (Windows Installer Xml toolset).
PLINQO is an enhanced alternative for the most popular Object Relational Mapping frameworks. It is a set of CodeSmith Templates designed to simplify the creation and maintenance of data models, as well as provide you with an easy to use data access layer that adhears to best practices.
The CSLA Templates are a set of templates built around Rockford Lhotka's CSLA Framework. Featuring the most complete set of templates on the market!
The .netTiers architecture is built upon the Microsoft Enterprise Library Application Blocks.
Our NHibernate templates will get any new or existing NHibernate project running in minutes.
The Kinetic Framework is an extensible business and data layer framework targeting the Microsoft technologies.
Premier Support is our support service agreement and can be purchased for $99/user/year for Generator.
Premier Support entitles you to the following:
- Free product enhancement updates.
- Guaranteed free upgrade to the next version of CodeSmith Generator.
- Ability to renew the support subscription.
- Access to bug fixes and nightly builds without waiting for official releases
- Access to technical support help from the CodeSmith support staff with a guaranteed response time of 48hrs*.
Each purchase of a Generator license comes with 30 days of Premier Support and can be upgraded to a year. If you renew you Premier Support within that 30 days there are no catch-up costs!
Users without Premier Support will be charged a $75 support fee per incident.
You can contact support using the contact us page. Any support emails that we receive from users who have purchased Premier Support will be automatically redirected to the Premier Support queue.
If you have already purchased CodeSmith Generator you can add or renew Premier Support for your CodeSmith Generator license. If you would like to add or renew support for your license, please use this form.
Be sure you get placed in our priority support queue, and get free upgrades between major versions.
For additional options, please visit the contact us page.
CodeSmith Generator offers online help documentation. This documentation includes a Generator User's Guide, as well as coverage of the Generator API documentation.