Are there any .NET tools that can create forms based on some kind of metadata?

I want to describe a form (fields with types, names, validation rules) through some xml or dsl. Then, at runtime, my code passes this tool metadata, it generates a form (web, win forms, whatever), it is displayed to the user, the user enters data, pushes OK, the tool calls my code through some delegate with values, a dictionary of values. Of course, I can write such a thing myself, but maybe I do not need it?

+4
source share
5 answers

Maybe you should take a look at NakedObjects . This works correctly: from code to data, and not vice versa. Otherwise, you cannot adequately model the behavior. For other platforms (Bamboo, java, Smalltalk), other implementations exist.

+2
source

Dynamic data will do this from a model like Linq to SQL or EntityFramework, but not xml. It manages data and uses templates.

Click

Hope this helps.

+1
source

If you look at the code for WinForms, the controls are built and configured in the code.

If you decompile (for example, via Reflector) an assembly created from web .aspx or .ascx into WebForms, this is just code that outputs HTML (many calls to Response.Write via HtmlTextWriter .

XAML is just a way to define a graph of objects.

This is just a code.

There are no reasons why you cannot:

  • Create your own custom code generator to generate user interface code at compile time.
  • Create the "controls" needed for some DSLs at runtime.
+1
source

I know only one tool from the MS world that is close to your requirements - MS InfoPath. My experience is that everything, including custom development, is better than InfoPath.

0
source

Ironspeed does what you need. However, I heard that some have a bad experience.

0
source

All Articles