Reputation: 43
I have the following requirement: In C#2.0, Given a device configuration in xml format and a schema automatically create a UI displaying the xml. This ui could change the xml and needs to perform validation on the schema.
I thought of a file defining for each xpath how to display it in UI (and a default behaviour for unspecified elements).
Is any one aware of existing solutions in C#2.0 producing winform?
Upvotes: 1
Views: 555
Reputation: 10650
One way is to use XSLT to transform the XML the way you want. You can transform it to HTML and put the output into a Windows Forms WebBrowser control. Or you could use XSLT to transform your XML + XSD into XAML.
Or, you could use XAML as your XML language, and you don't need your own schema, because you'd be using the XAML schema.
EDIT: This article - A Dynamically Generated XML Data Editor - on code project sounds closest to what you need.
Upvotes: 1