Solved

How to trriger an event when data in DBCombo is changed?

Posted on 1997-11-07
9
197 Views
Last Modified: 2008-03-06
I want to enable or disable a ListBox on the basis of a certain value of a DBCombo control. I have used mouseup and click and it works when these events are triggered but if I change it with keyboard it does not work. I have used change event but it does not work. I will be thankful for a suggestion.
khawarjawad@hotmail.com
0
Comment
Question by:Khawar091697
  • 4
  • 2
  • 2
  • +1
9 Comments
 
LVL 3

Expert Comment

by:ESI
ID: 1440113
The best way is to use either a static or global flag (a boolean variable) to "lock" the control, or check it's enable property to  immediately exit the event.

Hope it helps
0
 

Author Comment

by:Khawar091697
ID: 1440114
Edited text of question
0
 

Author Comment

by:Khawar091697
ID: 1440115
This is not my requirement. I want to know that which 'single event' is triggered when we change item either by mouse or by keyboard.
0
Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

 
LVL 3

Expert Comment

by:ESI
ID: 1440116
Try the SelChange event then
0
 

Author Comment

by:Khawar091697
ID: 1440117
But DBCombo don't have such event as SelChange? Kindly tell me some other way?
Thank You!
0
 
LVL 1

Expert Comment

by:Steve Groner
ID: 1440118
Perhaps you should check into subclassing the Combo box, capture the drop down, change, or roll up event if needed.
0
 

Author Comment

by:Khawar091697
ID: 1440119
Thank you Mr. sgroner for having a comment on my question.

Can you please explain, what does the term "subclassing the ComboBox" refer to? I cannot undrstand that.
0
 

Accepted Solution

by:
Grant082997 earned 20 total points
ID: 1440120
If you are using the DBCombo that came with VB5, then you should install service pack 2.  This corrects the problem of the DBCombo_Change event not firing.

For more info, check out http://support.microsoft.com/support/kb/articles/Q171/7/98.asp
0
 

Expert Comment

by:Grant082997
ID: 1440121
I was mistaken.  The correct web page for this is http://support.microsoft.com/support/kb/articles/Q171/8/04.asp

Sorry about that.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Using "ScreenUpdating" 6 73
Microsoft Access combo box help 2 50
Excel Automation VBA 19 88
VB6 common control 6 sp6 object library not registerd 3 22
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question