472,143 Members | 1,578 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,143 software developers and data experts.

disable f4 key for combo box

When your selected on a combo box, and hit F4, it shows
the drop down list.

So how do i stop the F4 key from bringing up the drop down
list on a combo box?
Nov 20 '05 #1
1 3084
Hello,

"Dante" <da******@hotmail.com> schrieb:
When your selected on a combo box, and hit F4, it shows
the drop down list.

So how do i stop the F4 key from bringing up the drop down
list on a combo box?


\\\
Private Declare Auto Function SendMessage Lib "user32.dll" ( _
ByVal hwnd As IntPtr, _
ByVal wMsg As Int32, _
ByVal wParam As Boolean, _
Optional ByVal lParam As Int32 = 0 _
) As Int32

Private Const CB_SETEXTENDEDUI As Int32 = &H155
..
..
..

' Disable F4.
SendMessage(Me.ComboBox1.Handle, CB_SETEXTENDEDUI, True)
///

For enabling F4, pass 'False' in the last parameter.

--
Herfried K. Wagner
MVP VB Classic, VB.NET
http://www.mvps.org/dotnet
Nov 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

3 posts views Thread by MervinJadhav | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.