Vote count:
0
Consider a very basic form with a simple combo box
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
this.comboBox1.Items.Add("test1");
this.comboBox1.Items.Add("test2");
this.comboBox1.Items.Add("test3");
}
private void Form1_Load(object sender, EventArgs e)
{
this.comboBox1.SelectedIndexChanged += (o, args) =>
{
MessageBox.Show("Combo box changed!");
};
}
}
Expand the dropdown using mouse and select any item using keyboard.
It fires twice (The message box appears twice)
Any ideas why?
asked 1 min ago
Simple Combobox in Winforms - Firing twice (Use mouse to expand combobox and select a item using keyboard)
Aucun commentaire:
Enregistrer un commentaire