07-23-2007 05:09 AM
07-23-2007 11:05 AM
I'm not 100% sure I understand your problem, but here are somethings to consider.
- the Enabled property of a Cut/Copy/Paste/Delete Command varies dynamically according to the current selection and focus. Make sure your toolbar or toolbar buttons do not steal the focus.
- Are you using TestStand buttons? In 4.0, you can set the button image and you can set Button.Style to ButtonStyle_ToolBar. If this works for you, it could save some work.
- If you aren't using TestStand buttons, then you need to decide when to dim or enable the buttons. Some options are:
a) Use a timer to periodically update them. It is okay if there is a slight lag because even if the button is still enabled when it shouldn't be, the command will be correctly enabled/disabled when the button invokes it..
b) For each native button, connected the same command to a TestStand button that you hide. Handle the ConnectionActivity event for the TestStand button and update the corresponding native button in the handler.
07-23-2007 02:56 PM
07-25-2007 02:55 AM