Microsoft KB Archive/90853

{|
 * width="100%"|

INF: Double-click Also Executes OnPush Twice
'Article ID: Q90853

Creation Date: 22-OCT-1992

Revision Date: 19-SEP-1996' The information in this article applies to:


 * Microsoft Access versions 1.0 and 1.1

SUMMARY

On a form using the OnPush and OnDblClick events, the double-click runs the OnPush event before and after the OnDblClick event.

MORE INFORMATION

If you want the OnDblClick event to execute without the OnPush event, you must put an explicit CancelEvent action at the end of the OnDblClick macro. Otherwise, both clicks will execute the macro assigned to the OnPush event.

Steps to Reproduce Behavior

 Create a macro with a beep action. Save it as Macro1. Create a second macro with a MsgBox action. Save it as Macro2. Create a blank form and add a command button. Set the OnPush property for the command button to Macro1 and the OnDblClick property to Macro2. From the View menu, choose Form.  Double-click the command button. Note that the OnPush event is activated before and after the OnDblClick event. 
 * }

-

"THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED &quot;AS IS&quot; WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY." '' ©1997 Microsoft Corporation. All rights reserved. Legal Notices.

''

Additional reference words: 1.00 1.10

KBCategory: kbusage

KBSubcategory: FmsEvnt