Solved

Stop beep when click on locked control

Posted on 2004-09-09
8
371 Views
Last Modified: 2008-01-09
In Access 2000,

I have a form which contains a checkbox bound to a formula.  The checkbox is enabled but lock.

I am doing some processing on the MouseDown event of the checkbox and everything is working fine ... except that my speaker was off.

When I tried it on another PC, I notice that Access is doing "beep" every time I click over the checkbox.  This is annoying.

Does someone lnow how to prevent the beep (other the turning the speaker off wise guys ;-) ) ?

Can I remove the click form teh event queue after I process teh OnMouseDown event (the beep is heard after my event has run) ?


Thanks
0
Comment
Question by:ragoran
[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
  • 4
  • 2
  • 2
8 Comments
 
LVL 2

Expert Comment

by:JakeBushnell
ID: 12023349
Hi Ragoran, is there an alert box or any message that pops up in the code for that event? By default a locked control does not have any a "beep" or any sound for that matter. However, if you may have something triggers that beep in you code.

If you could post what happens in that event we can take a look for you.

Jake Bushnell
0
 
LVL 41

Expert Comment

by:shanesuebsahakarn
ID: 12023388
Haven't tried it, but have you tried setting Button=0 before you exit the event?
0
 
LVL 14

Author Comment

by:ragoran
ID: 12025853

There are no msgbox, no popup or anything, just beeps.

Another easy way to reproduce this behavior is:

1 - Create a new form
2 - put a checkbos on it, set the control source to "=true"
3- run the form, click on the checkbox --> beep


I think it is the way that Access is notifying the user that it can't accept this event because the checkbox can't be change interactively because it is bound to a formula, thus locked.

But I want to trap the event to do something.  

Because the control is to be used in a continuous form, it can't be unbound.

This is frustrating because I was about to post a solution to the continous form multi-select question we get every other days.  As well as highlighting the current row in a continuous form, etc. And this is the last detail not working...


0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 14

Author Comment

by:ragoran
ID: 12026052
Shane:

Good try, but setting Button = 0 doesn't change a thing.  

It make sense as the Button parameters is declared byval, not byRef, so the calling (event handler) does not see the change.

0
 
LVL 41

Accepted Solution

by:
shanesuebsahakarn earned 75 total points
ID: 12026078
Hmm - the same method works with the KeyDown event (setting the KeyCode=0 prevents further processing of the keyboard buffer) so I thought that might work. Oh well...

On a side point, Access (2002) does not beep for me when I try to click on a field bound to a calculation.
0
 
LVL 14

Author Comment

by:ragoran
ID: 12026159
Oh, I will try tonigh at home where I have Access 2003 installed...

You are right about the keyDown event... but this parameter is noy byRef either... that I don't understand.

I just notice that when the access beeps, I also have a message in the status bar saying "Control can't be edited, it is bound to the expression 'False' "

0
 
LVL 2

Assisted Solution

by:JakeBushnell
JakeBushnell earned 50 total points
ID: 12027539
Hi ragorn, I tried what you mention before my first post. It did not beeb at all. I am using 2002.
Jake Bushnell
0
 
LVL 14

Author Comment

by:ragoran
ID: 12219221
Apparently, it is a set behavior in Access 2000 (and before?) but both Access 2002 and 2003 don't beep.  I guess I will leave it at that for the moment.

Thanks you all

Ragoran
0

Featured Post

Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

Question has a verified solution.

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

Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.

696 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