Microsoft KB Archive/93191

From BetaArchive Wiki
< Microsoft KB Archive
Revision as of 13:18, 21 July 2020 by X010 (talk | contribs) (Text replacement - "&" to "&")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Microsoft Knowledge Base

WMenu, XSelectMenuItem Routines Fail with Some Applications

Last reviewed: October 19, 1994
Article ID: Q93191

The information in this article applies to:

  • Microsoft Test for Windows, version 1.0

SYMPTOMS

The WMenu or XSelectMenuItem routines in Microsoft Test may fail to activate the desired menu on some Windows applications. For example, WMenu does not work reliably on the Paintbrush application provided with Windows, version 3.1.

RESOLUTION

To work around this problem, you can first pull down one of the application's menus, either by sending the appropriate accelerator keystroke, or queuing a mouse click event that clicks the menu. Once any menu is active, the WMenu and XSelectMenuItem routines work reliably.

STATUS

Microsoft has confirmed this to be a bug in Microsoft Test version 1.0 for Windows. This bug was corrected in Microsoft Test version 2.0 for Windows.

MORE INFORMATION

The following example test script demonstrates both the problem and the workaround:

'$define TESTCTRL
'$define TESTEVNT
'$include: 'MSTEST.INC'

Run "PBRUSH.EXE", Nowait

' This fails to activate the file menu or bring up the 'Open file'
' dialog box.

WMenu "&File" WMenu "&Open..."

Pause "Click 'OK' to correctly activate the menu"

' To work around this problem, send the appropriate
' accelerator to activate any menu, then call WMenu.

DoKeys "%h" ' Pull down the Help menu. WMenu "&File" WMenu "&Open..."


Additional reference words: buglist1.00 fixlist2.00 1.00 buglist1.00

KBCategory: kbtool kbprg kbbuglist kbfixlist
KBSubcategory:


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" 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.

Last reviewed: October 19, 1994
©1997 Microsoft Corporation. All rights reserved. Legal Notices.