Click here to Skip to main content
15,894,825 members
Articles / Programming Languages / XML

XML Schema Reader Writer Plugin for VS 2005/2008

Rate me:
Please Sign up or sign in to vote.
4.43/5 (5 votes)
17 Apr 2009CPOL3 min read 32.9K   716   11  
Schema based XML reader writer implemented as .NET COM generator
using System;
using System.Collections.Generic;
using System.Text;
using System.Xml.Serialization;
using System.IO;
using System.Runtime;
using System.Runtime.InteropServices;

namespace jjjjjjjjjjjjj
{
    class Program
    {
        static void Main(string[] args)
        {
            //Uncomment after executing the plugin

            //Type factType = typeof(ComXml.XmlFactory); // Type.GetTypeFromCLSID(new Guid("2C349B04-72F8-4F22-90A4-0C610790C380"));
            //ComXml.Interfaces.IXmlFactory fact = Activator.CreateInstance(factType) as ComXml.Interfaces.IXmlFactory;
            //ComXml.Interfaces.IXmlWriter writer = fact.CreateWriter();
            //ComXml.Interfaces.IXmlReader reader = fact.CreateReader();

            //ComXml.Interfaces.IComputer comp = fact.CreateComputer();
            //ComXml.Interfaces.IApplication app = fact.CreateApplication();
            //ComXml.Interfaces.IApplication app2 = fact.CreateApplication();

            //app.name = "MyApp";
            //app.Type = ComXml.Interfaces.ApplicationType.User;

            //app2.Type = ComXml.Interfaces.ApplicationType.System;
            //app2.name = "My2ndApp";

            //comp.name = "Basta";
            //comp.ips = new string[] { "192.168.10.3", "192.168.11.45" };
            //comp.Application = new ComXml.Interfaces.IApplication[] { app, app2 };
            //writer.WriteToFile("c:\\1.xml", comp);
            //comp = reader.ReadFromFile("c:\\1.xml");
        }
    }
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Team Leader
Israel Israel
Born and raised in Israel, caught the programming virus at the age of 15.
Since than I can't stop coding.

Comments and Discussions