C# - Library for creating XML editor based on XSD?

"YOU AND THE ART OF ONLINE DATING" is the only product on the market that will take you step-by-step through the process of online dating, provide you with the resources to help ensure success. Get it now!

Including schema validation built in! – Paul Apr 6 at 17:04 Well I don't need an application that can do this. I need to make my own module for my own application.

That's why I said I need a library/class... – Gapipro Apr 6 at 19:17 @Gapi: Visual Studio is extremely extensible. In particular, you can create applications based on Visual Studio. See the Visual Studio 2010 SDK.In particular, look at the Visual Studio Shell.

Every time you've used Visual Studio, you've used this ability to build on top of the Visual Studio Shell. That's what Microsoft does to create the packages you buy off the shelf. – John Saunders Apr 6 at 19:27 I will look into this.

Thanks – Gapipro Apr 6 at 5:48.

codeproject.com/KBecause s/diy-intellisense. Aspx Should give you a good head-start.

Try Actipro's SyntaxEditor. It's available for WinForms, WPF, and Silverlight and includes support for abstract syntax tree construction, common IntelliSense-like visual cues etc.

We are using SyntaxBox in one of our projects. Performance isn't that good, there are commercial products out there that are also rather inexpensive and of high quality. In addition, I believe Scintilla is the most powerful free syntax-coloring editor component out there.

You can use the . NET Class: XmlSchemaValidator The 2 key methods are: GetExpectedParticles and GetExpectedAttributes that return an XmlSchemaObject. Before you use these you need to setup the context for the validator by validating all preceding and ancestor elements and attributes.

You will also need to use methods on the classes derived from XmlSchemaObject, these expose the various parts of the post-compile Schema Object Model. The model hierarchy itelf closely resembles the XML structure that you will find in XSD files. You will probably need to use recursion and there are quite a few potential traps, for example when handling substitution groups, but a reasonable solution can be completed in around 2000 lines of c#.

Great, only problem is that Silverlight doesn't have this class =) – Gapipro Apr 7 at 5:47 Ok, I tested this class. It doesn't work as I exacted. With this class I can only get expected elements based on current hierarchy of validator object(XSD) and not based on created XML file.

– Gapipro Apr 10 at 16:57 You would need to get the node path to the caret position in the XML, then iterate through the nodes to set up the validator object context first - before the GetExpectedParticles call. Even after that, you need to convert the expected particle, depending on type, XSD is non-trivial, hence 2000 lines of code. – pgfearo Sep 8 at 4:05.

The 2 key methods are: GetExpectedParticles and GetExpectedAttributes that return an XmlSchemaObject. Before you use these you need to setup the context for the validator by validating all preceding and ancestor elements and attributes. You will also need to use methods on the classes derived from XmlSchemaObject, these expose the various parts of the post-compile Schema Object Model.

The model hierarchy itelf closely resembles the XML structure that you will find in XSD files. You will probably need to use recursion and there are quite a few potential traps, for example when handling substitution groups, but a reasonable solution can be completed in around 2000 lines of c#.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions