Solved

DBCombo selecting

Posted on 1998-07-30
2
170 Views
Last Modified: 2010-05-03
I have am using a DBCombo box and I would like to restrict the user to only selecting items from the list. However, if I set the lock property to true the you can't select from the list. And if I set the lock property to false you can type anything you want in the text box.
How can I do this?
0
Comment
Question by:chaos_59
2 Comments
 

Accepted Solution

by:
mskannan earned 50 total points
ID: 1467333
Hi chaos_59,
In the keypress event of DBCombo just type in
keyascii = 0
They can't enter any thing.Also ensure that you are checking for Tab/Enter keys.
I think it should solve your problem.

mskannan

0
 

Expert Comment

by:hansbos
ID: 1467334
Chaos_59,

Try setting the property Style of the DBComboBox to
2 - dbcDropdownList.

Hans
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

744 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now