Prevent drop-down of combo box

G

Guest

I have a combo box on my form. In the OnMouseDown property I have a code
that opens a form frmCalendar that has a calendar control on it. A date is
selected from the calendar control by the user and a code returns the value
to the combo box.
The issue that I have here is that everytime the user clicks on the combo
box the dropdown list appears (there is no information in this list) and
frmCalendar is opened. I don't want the dropdown list to appear. Is there a
way by which I can accomplish this? The reason why I have a combo box is
that with a combo box the user knows that they can click on the dropdown
arrow and have a calendar pop up. If there is any other better way of doing
this I am open to suggestions.

FYI, I have several forms with several date fields (read combo boxes).

Any help would be appreciated.

Thanks
 
R

Rick B

Then why are you using a combo-box if you don't want combo-box reflexes? Us
a different type of control.
 
R

Rick B

Sorry - I hit send too soon.

I'd put a button next to my date field and have them click the button (if it
were me).
 
G

Guest

I could have created a button to open the calendar form, if I had not gone as
far as I have with my database. Now that I have about 10 forms each with
several date fields, I don't want to reorganize all my forms to fit a button
on each one of them for every date field. Do you have any suggestions on an
alternative to this?

Thanks for your response.
 
C

CJ

FWIW

The button makes way more sense. You need to go to all of these forms and
code them somehow so that the combo boxes do not open anyway, so why not
make a wee little button that opens the calendar.

If you don't......

1. End users of the database are going to complain about the empty drop
downs..."Which ones contain something, which ones don't."
2. Knowing that you have empty combo boxes is going to drive you crazy until
you fix it anyway because you know it's not correct.

Make the button and copy and paste it and it's code everywhere you need it.
Change the names slightly so that you do not have duplicates. Launch the
database. Pat yourself on the back for doing the job properly. Put your feet
up and enjoy your favorite cold refreshment.

;-)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top