WarthogDJ
Messages postés202Date d'inscriptiondimanche 4 novembre 2007StatutMembreDernière intervention 5 septembre 2020
-
Modifié par WarthogDJ le 20/01/2013 à 12:14
Bonjour,
Je suis en train de coder un serveur dans lequel j'ai implémenté un webservice (WCF)
J'utilise donc entre autre dans ma solution un projet win form.
C'est une console (j'utilise un richtext box) Bref tout cela marche.
Cependant j'ai aussi un menustrip sur lequel se trouve un shapecontainer dans lequel j'ai deux shape un oval et un rectangle.
Mon problème est que quand ma fenêtre s'agrandit (apres une réduction dans la barre d'icones) mes shapes disparaissent.
Voici le code concernant le notify icon.
// evement Resize de mon Form
private void FormBirdyWebServer_Resize(object sender, EventArgs e)
{
if (this.checkBoxSysTray.Checked == true)
{
if (FormWindowState.Minimized == this.WindowState)
{
this.notifyIconBirdy.Visible = true;
this.notifyIconBirdy.ShowBalloonTip(500);
this.Hide();
}
else if (FormWindowState.Normal == this.WindowState)
{
this.notifyIconBirdy.Visible = false;
this.shapeContainerIcons.BringToFront();
this.rectangleShapeServiceStopped.BringToFront();
this.ovalShapeServiceStarted.BringToFront();
}
}
}
//Comportement apres un click de souris de mon notify icon
private void notifyIconBirdy_MouseUp(object sender, MouseEventArgs e)
{
if (e.Button == MouseButtons.Left)
{
this.ShowWindow();
this.notifyIconBirdy.Visible = false;
}
else
if (e.Button == MouseButtons.Right)
{
this.contextMenuStripSysTray.Show();
}
}
*************Une signature est un gribouillis ****************
C'est important?************************Au yeux des gens oui.