private void listBoxItems_MouseDoubleClick(object sender, MouseEventArgs e) { int index = this.listBoxItems.IndexFromPoint(e.Location); if (index != System.Windows.Forms.ListBox.NoMatches) { this.addCommand(0, index); } }