how to add dropdown item in a menu w/ shortcut key? what code should i write?
Printable View
how to add dropdown item in a menu w/ shortcut key? what code should i write?
You would need to capture the KeyDown event of your form and check to see if the keys pressed were your shortcut keys and if so, bring up a dialog box that lets the user enter the text they want to be added to the drop down, then add it like so:
vb Code:
Dim UserInput As String 'Set the UserInput string value from a text box etc here MyComboBox.Items.Add(UserInput)