CodeSmith Professional: Generate Code Rapidly
CodeSmith Professional Edition is code-generation tool that uses a template-based approach with a syntax similar to ASP.NET's. Plus a quick look at Graphics Server .NET.
Nearly every non-trivial software development project has at least some code that you've probably written dozens of times: standard CRUD stored procedures, data-access code, objects based on your chosen framework, and so on. Any object-oriented application is a great candidate for using code-generation tools to create this kind of redundant code. CodeSmith Tools' CodeSmith 3.1 Professional Edition is the first commercial version of a freeware code-generation tool.
CodeSmith's template-based approach to code generation uses a tag syntax similar to ASP.NET's, making it a familiar environment for many developers (see Figure 1). The product comes with a variety of pre-built templates to get you started, including some for generating stored procedures based on a database schema, creating objects based on Rocky Lhotka's CSLA framework, creating common collections objects, and other common programming tasks. You can modify the templates as you wish or use any of them as a starting point for custom templates.
CodeSmith Professional Edition consists of two primary tools: CodeSmith Explorer and CodeSmith Studio. CodeSmith Explorer, available as both a standalone version and a VS add-in, provides a control panel for running templates, editing them using a text editor of your choice, and maintaining templates. CodeSmith Studio is a complete template development environment that includes a code editor that rivals that in VS. It also features tools to write .NET code using the CodeSmith API and build the template when you're ready. The company has done a great job providing template tools that any VS developer will be comfortable with.
CodeSmith, based on the .NET Framework, uses ASP.NET's tag syntax and allows code-generation automation using C# and VB.NET. CodeSmith can generate any kind of text-based files you want to create a template for, including stored procedures, Java, and documentation.
CodeSmith 3.1 includes a complete online help file that does a great job of documenting the product and providing a complete reference to its features. It'll take some work to learn how to use the product effectively, but the documentation, sample templates, and online forums provide all the help you'll need.
CodeSmith 3.1 is an impressive product. Eric Smith, CodeSmith's creator, recently teamed up with Rob Howard and Telligent Systems to form CodeSmith Tools to continue to develop the product. Given its current high quality and the new partnership, CodeSmith has a bright future.
CodeSmith 3.1 Professional Edition
Quick Facts: Complete code-generation package based on templates and the .NET Framework.
Pros: Great tools for managing and editing templates; includes many usable templates; reasonably priced for the value.
Cons: Takes some time and effort to learn to use effectively.
Bring Your Data to Life
>by Andy Clark
Graphics Server .NET provides an outstanding set of tools for adding graphs to your VS.NET applications. These tools work within both WinForms and ASP.NET, and they support a large variety of graphs with an object-oriented API that is both powerful and easy to use. Version 2.5 adds support for widgets and other graphics devices that take charting well beyond the presentation graphics arena (see Figure 1).
Graphics Server .NET supports all of the standard graphs, including pie, line, area, bar, and Gantt charts. Most of these charts have both 2-D and 3-D versions. It also supports radar, scatter, polar, and a variety of other graphs you might not have heard of. All of these graphs are implemented with the developer in mind. You can control fonts, scales, captions, and overall style. Further, you can easily set the graphs to show lines at set standard deviations from the norm, a common requirement for quality measurements. You can also color-code unusual values automatically. You can configure these features at design time using Graphics Server's Chart, Layout, and Style designers. The WinForms version of Graphics Server .NET also provides property pages that allow users to modify chart characteristics at run time without any additional developer code.
Graphics Server .NET 2.5 goes beyond presentation graphics to support widgets, which are special devices such as thermometers, meters, gauges, and sliders that you can use for dashboards or as special controls. These devices support a rich event interface so that you can allow users to modify data directly using widgets. The devices can also help users make quick observations about important status variables.
Note that there is strong support for event-based development throughout Graphics Server .NET. As you would expect, some events are available in the WinForms version, but not the ASP.NET version. However, the ASP.NET version provides tools for managing the large number of images that can pile up on a Web site. Graphics Server draws a new image and stores it on your Web site whenever a user creates a new graph. Graphics Server provides properties to prevent these image files from building up.
Graphics Server's support is both responsive and knowledgeable, and the product documentation is excellent. It features both introductory and reference documentation and lots of sample code for both C# and VB.NET. All of this is integrated into a Resource Center that does a good job of showcasing what is possible with the product's amazing variety of graphs.
Graphics Server is an impressive product that supports many different graphs in ASP.NET and WinForms, as well as custom-developed graph types. It's easy to use and strongly supported. I would like to see a document that clearly delineates what requires additional scripting in ASP.NET, but you can deduce most of the differences between WinForms and ASP.NET with a little common sense. Graphics Server .NET is a strong tool for helping your users understand and manage their data.
Graphics Server .NET 2.5
Graphics Server Technologies
Phone: 800-231-1293; 206-625-6900
Price: $2,999 (site license)
Quick Facts: Adds support for a variety of graphs to WinForms and ASP.NET.
Pros: Supports a wide variety of graphs with lots of flexibility.
Cons: Documentation doesn't clarify which functions require additional scripting within ASP.NET.
Don Kiely is a senior technology consultant in Fairbanks, Alaska. When he isn't writing software, he's writing about it, speaking about it at conferences, and training developers in it. Reach him at email@example.com.