Microsoft
Software
Hardware
Network
Question : ToolStrip textbox focus.
Dear All Experts,
in my form, i have toolstrip with combobox1 and textbox1. in my scenario when i select combobox1 then textbox1 will get focus. this is my code:
Private Sub cboSearchBy_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cboSearchBy.Click
If Asc(e.KeyChar) = Keys.Enter Then
txtSearch.Focus()
e.Handled = True
End If
End Sub
this code given me an error:
'KeyChar' is not a member of 'system.eventArgs.'
Any help please, i used VB.Net 2005
Best Regards,
Beginning VB.Net
Answer : ToolStrip textbox focus.
Why are you dealing with key characters in a combo box handler? Usually one clicks on a combo box with the mouse, and you seem to be using the MouseClick event. Just remove the If statement and you should be all set.
Random Solutions
MS Virtual Machine and disk2vhd
How do I change the collating sequence properties at both the database and sql engine level for both SQL 2000 and 2005?
Exchange Server Wont Start
Outlook 2007 Corrupt ost file
Microsoft® Hyper-V" Server 2008 R2 is out, and now ?
Can not find active desktop HTML file.
TreeView BOM
Virtualizing Backup Exec 12.5 on Hyper-V
Access 2007 getting message "you do not have the necessary permissions to use"
The Microsoft Jet database engine could not find the object 'Databases'. Make sure the object exists and that you spell its name and the path name correctly.