How to Really Depress a Button! - Greg Collins

InfoPath Dev

This Blog


Greg Collins

How to Really Depress a Button!

Status: Not fixed as of the InfoPath 2003 SP2 release. 

I uncovered this bug merely on 2004-07-03 and reported it to my Microsoft contacts.

I discovered that you can get a button into a depressed state and have it stuck there until you release it with another click. It's really not a hard thing to do. And what's worse is then when the button is placed into this state it will not perform its assigned functionality because the click was never released. It is not until the click is released that the rules and code behind the button are processed.

Here are the steps:

  1. Start with a new blank form.
  2. Insert a button into the view.
  3. Preview the form.
  4. Left-click the button, but don’t release.
  5. Right-click the button, and then release.
  6. Now release the left-click.

Results: The button stays in a depressed state.

  1. Left-click the button.

Results: The button returns to normal state.

  1. Close the preview.
  2. Add a rule to the button to show a dialog box message.
  3. Preview the form.
  4. Perform steps 4-6 above.

Results: The rule did not fire.

  1. Left-click the button.

Results: The rule fires.

  1. Close the preview.

You can also use a UI.Alert() in place of the rule and the effect is the same. If you use both a rule and an Alert, the affect is the same, only when the button is finally released, the rule fires and then the code, as expected.

©2004 Greg Collins. All rights reserved. Licensed to Autonomy Systems, LLC for display on


No Comments
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.