Click here to Skip to main content
15,896,606 members
Articles / Programming Languages / C#

Simple calendar reminder application in WPF and MS SQL Server 2005

Rate me:
Please Sign up or sign in to vote.
1.00/5 (1 vote)
25 Aug 2010CPOL3 min read 30.9K   1.3K   6  
Simple calendar reminder application in WPF and MS SQL Server 2005
/////////////////////////////////////////
// Simple event remember used WPF and MS SQL Server 2005
// Autor Bruh Andrey. June 2006
/////////////////////////////////////////

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Diagnostics;
using System.Linq;
using System.Text;

namespace Remember_v
{
    /// <summary>
    /// Tray icon component
    /// </summary>
    public partial class Trey : Component
    {
        #region Data

        /// <summary>
        /// Main class
        /// </summary>
        private Window1 win = null;

        #endregion

        #region Constructor

        /// <summary>
        /// Constructor
        /// </summary>
        public Trey(Window1 wnd)
        {
            win = wnd;
            InitializeComponent();
            showWindow.Click += new EventHandler(show_Click);
            hideWindow.Click += new EventHandler(hide_Click);
            showWindow.Enabled = false;
        }

        #endregion

        #region Methods

        /// <summary>
        /// Hide
        /// </summary>
        public void hide_Click(object sender, EventArgs e)
        {
            showWindow.Enabled = true;
            hideWindow.Enabled = false;
            win.Hide();
        }

        /// <summary>
        /// Show
        /// </summary>
        void show_Click(object sender, EventArgs e)
        {
            showWindow.Enabled = false;
            hideWindow.Enabled = true;
            win.Show(); 
            win.Activate();
        }

        #endregion
    }
}

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
Software Developer Soft Xpansion
Ukraine Ukraine
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions