Digg StumbleUpon LinkedIn YouTube Flickr Facebook Twitter RSS Reset

Exemple d’utilisation de l’etat ‘au repos’

Utilitaire,Plateforme:,non,edité
{filelink=17882}

using System;
using System.Windows.Forms;
 
namespace mesexemples
{
    public class EvenementIdle : Form
    {
        public EvenementIdle()
        {
            Text = "Exemple des événements 'Form'!";
        }
 
        public static void Main()
        {
            EvenementIdle FormObject = new EvenementIdle();
            ApplicationEventHandlerClass AppEvents = new ApplicationEventHandlerClass();
 
            Application.Idle += new EventHandler(AppEvents.OnIdle);
            Application.Run(FormObject);
        }
 
    }
 
    public class ApplicationEventHandlerClass
    {
        public void OnIdle(object sender, EventArgs e)
        {
            Console.WriteLine("L'application est au repos.");
        }
    }
 
}

No comments yet.

Leave a Comment