Vous êtes sur la page 1sur 5

Cdigo del Panel Principal

Esta ventana es el panel principal necesario para las Altas, Bajas y Cambios de Clientes, Productos, Proveedores y Ventas. Coding:
using using using using using using using using System; System.Collections.Generic; System.ComponentModel; System.Data; System.Drawing; System.Linq; System.Text; System.Windows.Forms;

namespace GoldenStar { public partial class Form4 : Form { public Form4() { InitializeComponent(); }

private void pictureBox1_Click(object sender, EventArgs e) { timer1.Stop(); timer1.Start();

groupBox1.Visible = true; groupBox2.Visible = false; groupBox3.Visible = false; groupBox4.Visible = false; pictureBox1_1.Visible = true; pictureBox1_2.Visible = true; pictureBox1_3.Visible = true; pictureBox2_1.Visible = false; pictureBox2_2.Visible = false; pictureBox2_3.Visible = false; pictureBox3_1.Visible = false; pictureBox3_2.Visible = false; pictureBox3_3.Visible = false; pictureBox4_1.Visible = false; pictureBox4_2.Visible = false; pictureBox4_3.Visible = false; } private void pictureBox2_Click(object sender, EventArgs e) { timer1.Stop(); timer1.Start(); groupBox1.Visible = false; groupBox2.Visible = true; groupBox3.Visible = false; groupBox4.Visible = false; pictureBox1_1.Visible = false; pictureBox1_2.Visible = false; pictureBox1_3.Visible = false; pictureBox2_1.Visible = true; pictureBox2_2.Visible = true; pictureBox2_3.Visible = true; pictureBox3_1.Visible = false; pictureBox3_2.Visible = false; pictureBox3_3.Visible = false; pictureBox4_1.Visible = false; pictureBox4_2.Visible = false; pictureBox4_3.Visible = false; } private void pictureBox3_Click(object sender, EventArgs e) { timer1.Stop(); timer1.Start(); groupBox1.Visible = false; groupBox2.Visible = false; groupBox3.Visible = true; groupBox4.Visible = false; pictureBox1_1.Visible = false; pictureBox1_2.Visible = false; pictureBox1_3.Visible = false; pictureBox2_1.Visible = false; pictureBox2_2.Visible = false; pictureBox2_3.Visible = false; pictureBox3_1.Visible = true; pictureBox3_2.Visible = true; pictureBox3_3.Visible = true; pictureBox4_1.Visible = false; pictureBox4_2.Visible = false; pictureBox4_3.Visible = false; } private void pictureBox4_Click(object sender, EventArgs e) { timer1.Stop(); timer1.Start(); groupBox1.Visible = false; groupBox2.Visible = false; groupBox3.Visible = false; groupBox4.Visible = true; pictureBox1_1.Visible = false; pictureBox1_2.Visible = false; pictureBox1_3.Visible = false; pictureBox2_1.Visible = false; pictureBox2_2.Visible = false; pictureBox2_3.Visible = false; pictureBox3_1.Visible = false; pictureBox3_2.Visible = false; pictureBox3_3.Visible = false; pictureBox4_1.Visible = true; pictureBox4_2.Visible = true; pictureBox4_3.Visible = true; } private void pictureBox1_1_Click(object sender, EventArgs e) { Form5 ventana= new Form5(); ventana.ShowDialog();

} private void pictureBox1_2_Click(object sender, EventArgs e) { Form6 ventana = new Form6(); ventana.ShowDialog(); } private void pictureBox1_3_Click(object sender, EventArgs e) { Form7 ventana = new Form7(); ventana.ShowDialog(); } private void pictureBox2_1_Click(object sender, EventArgs e) { Form9 ventana = new Form9(); ventana.ShowDialog(); } private void pictureBox2_2_Click(object sender, EventArgs e) { Form10 ventana = new Form10(); ventana.ShowDialog(); } private void pictureBox2_3_Click(object sender, EventArgs e) { Form11 ventana = new Form11(); ventana.ShowDialog(); } private void pictureBox3_1_Click(object sender, EventArgs e) { Form12 ventana = new Form12(); ventana.ShowDialog(); } private void pictureBox3_2_Click(object sender, EventArgs e) { Form13 ventana = new Form13(); ventana.ShowDialog(); } private void pictureBox3_3_Click(object sender, EventArgs e) { Form14 ventana = new Form14(); ventana.ShowDialog(); } private void pictureBox4_1_Click(object sender, EventArgs e) { Form15 ventana = new Form15(); ventana.ShowDialog(); } private void pictureBox4_2_Click(object sender, EventArgs e) { Form16 ventana = new Form16(); ventana.ShowDialog(); }

private void pictureBox4_3_Click_1(object sender, EventArgs e) { Form17 ventana = new Form17(); ventana.ShowDialog(); } private void pictureBox5_MouseMove(object sender, MouseEventArgs e) { pictureBox5.Size = new Size(40, 40); } private void pictureBox5_MouseLeave(object sender, EventArgs e) { pictureBox5.Size = new Size(35, 35); } private void pictureBox5_Click(object sender, EventArgs e) { if (MessageBox.Show("Seguro que desea cerrar la aplicacin?", "Cerrar Aplicacin", MessageBoxButtons.YesNo) == DialogResult.Yes) { Application.Exit(); } } private void button1_Click(object sender, EventArgs e) { this.Close(); } private void Form4_Load(object sender, EventArgs e) { label3.Text = Global.usuario; } private void pictureBox1_MouseMove(object sender, MouseEventArgs e) { pictureBox1.Size = new Size(75, 75); } private void pictureBox1_MouseLeave(object sender, EventArgs e) { pictureBox1.Size = new Size(65, 65); } private void pictureBox2_MouseMove(object sender, MouseEventArgs e) { pictureBox2.Size = new Size(75, 75); } private void pictureBox2_MouseLeave(object sender, EventArgs e) { pictureBox2.Size = new Size(65, 65); } private void pictureBox3_MouseMove(object sender, MouseEventArgs e) { pictureBox3.Size = new Size(75, 75); } private void pictureBox3_MouseLeave(object sender, EventArgs e) { pictureBox3.Size = new Size(65, 65); } private void pictureBox4_MouseMove(object sender, MouseEventArgs e) { pictureBox4.Size = new Size(75, 75); } private void pictureBox4_MouseLeave(object sender, EventArgs e) { pictureBox4.Size = new Size(65, 65); } private void timer1_Tick(object sender, EventArgs e)

{ //limpio todo groupBox1.Visible = false; groupBox2.Visible = false; groupBox3.Visible = false; groupBox4.Visible = false; pictureBox1_1.Visible = false; pictureBox1_2.Visible = pictureBox1_3.Visible = false; pictureBox2_1.Visible = false; pictureBox2_2.Visible = pictureBox2_3.Visible = false; pictureBox3_1.Visible = false; pictureBox3_2.Visible = pictureBox3_3.Visible = false; pictureBox4_1.Visible = false; pictureBox4_2.Visible = pictureBox4_3.Visible = false; timer1.Stop(); } } }

false; false; false; false;