Programa Que Simula Un Teclado Virtual En Visual Studio
Enviado por • 19 de Mayo de 2015 • 2.255 Palabras (10 Páginas) • 219 Visitas
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace Teclado_virtual
{
public partial class Form27 : Form
{
public Form27()
{
InitializeComponent();
}
private void Form1_KeyDown(object sender, KeyEventArgs e)
{
lbl.Text = "" + e.KeyCode;
if (lbl.Text == "Q")
{
button1.BackColor = Color.Aqua;
}
else if (lbl.Text == "W")
{
button2.BackColor = Color.Blue;
}
else if (lbl.Text == "E")
{
button3.BackColor = Color.Blue;
}
else if (lbl.Text == "R")
{
button4.BackColor = Color.Blue;
}
else if (lbl.Text == "T")
{
button5.BackColor = Color.Blue;
}
else if (lbl.Text == "Y")
{
button6.BackColor = Color.Blue;
}
else if (lbl.Text == "U")
{
button7.BackColor = Color.Blue;
}
else if (lbl.Text == "I")
{
button8.BackColor = Color.Blue;
}
else if (lbl.Text == "O")
{
button9.BackColor = Color.Blue;
}
else if (lbl.Text == "P")
{
button10.BackColor = Color.Blue;
}
else if (lbl.Text == "A")
{
button11.BackColor = Color.Blue;
}
else if (lbl.Text == "S")
{
button12.BackColor = Color.Blue;
}
else if (lbl.Text == "D")
{
button13.BackColor = Color.Blue;
}
else if (lbl.Text == "F")
{
button14.BackColor = Color.Blue;
}
else if (lbl.Text == "G")
{
button15.BackColor = Color.Blue;
}
else if (lbl.Text == "H")
{
button16.BackColor = Color.Blue;
}
else if (lbl.Text == "J")
{
button17.BackColor = Color.Blue;
}
else if (lbl.Text == "K")
{
button18.BackColor = Color.Blue;
}
else if (lbl.Text == "L")
{
button19.BackColor = Color.Blue;
}
else if (lbl.Text == "Oemtilde")
...