Solved

DBCombo selecting

Posted on 1998-07-30
2
176 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
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

[Webinar] Code, Load, and Grow

Managing multiple websites, servers, applications, and security on a daily basis? Join us for a webinar on May 25th to learn how to simplify administration and management of virtual hosts for IT admins, create a secure environment, and deploy code more effectively and frequently.

Question has a verified solution.

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

Suggested Solutions

Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
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 utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

752 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