Click here to Skip to main content
15,886,830 members
Articles / Desktop Programming / Windows Forms

SQLite Compare Utility

Rate me:
Please Sign up or sign in to vote.
4.89/5 (68 votes)
21 Feb 2015LGPL35 min read 282.4K   37.1K   131  
Utility for comparing two SQLite database files for both structure and data
using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms;
using System.ComponentModel;
using System.Drawing;

namespace Liron.Windows.Forms
{
    public class MultiPanelPagesCollection : Control.ControlCollection
    {
        public MultiPanelPagesCollection(Control owner)
            : base(owner)
        {
            if (owner == null)
                throw new ArgumentNullException("owner", "Tried to create a MultiPanelPagesCollection with a null owner.");
            _owner = owner as MultiPanel;
            if (_owner == null)
                throw new ArgumentException("Tried to create a MultiPanelPagesCollection with a non-MultiPanel owner.", "owner");
        }

        public override void Add(Control value)
        {
            if (value == null)
                throw new ArgumentNullException("value", "Tried to add a null value to the MultiPanelPagesCollection.");
            MultiPanelPage p = value as MultiPanelPage;
            if (p == null)
                throw new ArgumentException("Tried to add a non-MultiPanelPage control to the MultiPanelPagesCollection", "value");
            p.SendToBack();
            base.Add(p);
        }

        public override void AddRange(Control[] controls)
        {
            foreach (MultiPanelPage p in controls)
                Add(p);
        }

        public override void Remove(Control value)
        {
            base.Remove(value);
        }

        public override int IndexOfKey(string key)
        {
            Control ctrl = base[key];
            return GetChildIndex(ctrl);
        }

        private MultiPanel _owner;
    }
}

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 GNU Lesser General Public License (LGPLv3)


Written By
Software Developer
Israel Israel
My name is Liron Levi and I'm developing software for fun & profit for 15 years already.

Comments and Discussions