Motivation II
I used consciously code generation one year ago. Nearly every day I was asked to implement and publish another contact form at our company’s homepage: Address fields, email address, custom validations…Actual a common task, but none of these forms looked like another, all of them asked for at least one different field. It was a stupid and boring. The approach was simple too: The form definition has been reduced to a xml based model. I used XSLT successful to transform these models to .ascx user controls.
The model files have been maintained by some power users. They did not know much about XML, but they have been able to alter existing model files to their needs. My function was reduced to validate the assigned model, to run the transformation and to publish the output to a web server. The time was reduced from about one hour per form to few minutes. As a side effect oversights diasppeared.