Eric J. Smith's Weblog
CodeSmith, .NET, etc...
-
CodeSmith as a job requirement
It’s a very cool feeling to see job postings that are listing an application that you built as a job requirement.
-
DNN300: Developing Custom DotNetNuke Modules
-
CodeSmith 3.0 Review by David Hayden
CodeSmith 3.0 Review by David Hayden
“… This is probably the defacto standard Code Generation Tool when working with databases. I have lost count as to how many templates I have to create web pages, usercontrols, business classes, data access objects, stored procedures, mapping files for O/R Mappers, etc. This is a must have tool to get you out of creating a lot of the monotonous plumbing associated with building applications. …” -
Is Dynamic SQL in Your Stored Procedures Vulnerable to SQL Injection?
Is Dynamic SQL in Your Stored Procedures Vulnerable to SQL Injection?
... article. Since writing sprocs as outlined in Erland's article can be tedious, I created a CodeSmith template that will do the work for you. You only need to input the table you wish to query, and CodeSmith will generate a complete sproc for you. ... -
ScriptTableData CodeSmith template that handles Text and NText data
Todd Carrico has posted a really nice modified version of the ScriptTableData.cst template. It handles text and ntext data types as well as adding some other nice features.
-
Google Earth!
I just had to say wow! Google Earth is awesome!
-
Rob Howard on .NET Rocks!
My partner Rob Howard also of Telligent Systems is on this weeks episode of the great .NET Rocks! internet talk show where he talks about his years with Microsoft working on the ASP.NET 1.0, 1.1, and 2.0 teams.
-
RTM on top of Whidbey Beta2 (and an ode to Code Generation)!!!
“Our application was just deployed in production on top of Whidbey Beta2!!! In addition to being a Whidbey success story, our application is a showcase for code generation techniques (and the great CodeSmith 2.6). In our DataAccess layer (about 4000 lines of code), a total of 10 lines were written by hand and that too to retrieve DB connection strings from configuration files. If we had been building on top of 1.1, we would have even bigger numbers for autogenerated lines of code) -- Whidbey generics eliminate the need to write code to create specialized collections of objects. In addition, we used xsd schemas to generate partial classes that were later extended using hand written code. If you ask me, creating a XSD file is much easier than defining a class and defining a whole bunch of get / set props (well, arguably the Whidbey IDE makes it trivial, but you get the point). The XSDs were processed using xsd.exe and XsdObjectGen (from MS). Both of these tools generate code from XSD definitions, but they work slightly differently. In addition, we used a couple of small homegrown tools to slightly tweak the output using regex (to change the generated class to "partial" for instance). Also, it's pretty worthwhile to have a tool that generates code intelligently based on some of timestamp mechanism so that build doesn't take a long time.”
-
CodeSmith Template Datatable Content Example
Dave Burke talks about using CodeSmith to generate type code enums from database table contents.
-
CodeSmith Generated Audit Log Triggers
Here is an article on The Code Project about how to use CodeSmith to generate audit log triggers for your database.